@stacksjs/orm 0.70.58 → 0.70.60

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.
Files changed (2) hide show
  1. package/dist/index.js +15 -15
  2. package/package.json +4 -4
package/dist/index.js CHANGED
@@ -1,31 +1,31 @@
1
1
  // @bun
2
- var xz=Object.create;var{getPrototypeOf:Az,defineProperty:J4,getOwnPropertyNames:Nz}=Object;var Iz=Object.prototype.hasOwnProperty;function Pz($){return this[$]}var vz,yz,Sz=($,Z,J)=>{var Y=$!=null&&typeof $==="object";if(Y){var X=Z?vz??=new WeakMap:yz??=new WeakMap,Q=X.get($);if(Q)return Q}J=$!=null?xz(Az($)):{};let G=Z||!$||!$.__esModule?J4(J,"default",{value:$,enumerable:!0}):J;for(let W of Nz($))if(!Iz.call(G,W))J4(G,W,{get:Pz.bind($,W),enumerable:!0});if(Y)X.set($,G);return G};var z=($,Z)=>()=>(Z||$((Z={exports:{}}).exports,Z),Z.exports);var q=import.meta.require;var g0=z((P4)=>{Object.defineProperty(P4,"__esModule",{value:!0});P4.CryptoProviderOnlySupportsAsyncError=P4.CryptoProvider=void 0;class N4{computeHMACSignature($,Z){throw Error("computeHMACSignature not implemented.")}computeHMACSignatureAsync($,Z){throw Error("computeHMACSignatureAsync not implemented.")}computeSHA256Async($){throw Error("computeSHA256 not implemented.")}}P4.CryptoProvider=N4;class I4 extends Error{}P4.CryptoProviderOnlySupportsAsyncError=I4});var j4=z((R4)=>{Object.defineProperty(R4,"__esModule",{value:!0});R4.NodeCryptoProvider=void 0;var y4=q("crypto"),QK=g0();class S4 extends QK.CryptoProvider{computeHMACSignature($,Z){return y4.createHmac("sha256",Z).update($,"utf8").digest("hex")}async computeHMACSignatureAsync($,Z){return await this.computeHMACSignature($,Z)}async computeSHA256Async($){return new Uint8Array(await y4.createHash("sha256").update($).digest())}}R4.NodeCryptoProvider=S4});var M0=z((_4)=>{Object.defineProperty(_4,"__esModule",{value:!0});_4.HttpClientResponse=_4.HttpClient=void 0;class D0{getClientName(){throw Error("getClientName not implemented.")}makeRequest($,Z,J,Y,X,Q,G,W){throw Error("makeRequest not implemented.")}static makeTimeoutError(){let $=TypeError(D0.TIMEOUT_ERROR_CODE);return $.code=D0.TIMEOUT_ERROR_CODE,$}}_4.HttpClient=D0;D0.CONNECTION_CLOSED_ERROR_CODES=["ECONNRESET","EPIPE"];D0.TIMEOUT_ERROR_CODE="ETIMEDOUT";class f4{constructor($,Z){this._statusCode=$,this._headers=Z}getStatusCode(){return this._statusCode}getHeaders(){return this._headers}getRawResponse(){throw Error("getRawResponse not implemented.")}toStream($){throw Error("toStream not implemented.")}toJSON(){throw Error("toJSON not implemented.")}}_4.HttpClientResponse=f4});var p4=z((l4)=>{Object.defineProperty(l4,"__esModule",{value:!0});l4.NodeHttpClientResponse=l4.NodeHttpClient=void 0;var M4=q("http"),h4=q("https"),h$=M0(),m4=M4.default||M4,u4=h4.default||h4,WK=new m4.Agent({keepAlive:!0}),VK=new u4.Agent({keepAlive:!0});class c4 extends h$.HttpClient{constructor($){super();this._agent=$}getClientName(){return"node"}makeRequest($,Z,J,Y,X,Q,G,W){let L=G==="http",B=this._agent;if(!B)B=L?WK:VK;return new Promise((U,K)=>{let T=(L?m4:u4).request({host:$,port:Z,path:J,method:Y,agent:B,headers:X,ciphers:"DEFAULT:!aNULL:!eNULL:!LOW:!EXPORT:!SSLv2:!MD5"});T.setTimeout(W,()=>{T.destroy(h$.HttpClient.makeTimeoutError())}),T.on("response",(w)=>{U(new m$(w))}),T.on("error",(w)=>{K(w)}),T.once("socket",(w)=>{if(w.connecting)w.once(L?"connect":"secureConnect",()=>{T.write(Q),T.end()});else T.write(Q),T.end()})})}}l4.NodeHttpClient=c4;class m$ extends h$.HttpClientResponse{constructor($){super($.statusCode,$.headers||{});this._res=$}getRawResponse(){return this._res}toStream($){return this._res.once("end",()=>$()),this._res}toJSON(){return new Promise(($,Z)=>{let J="";this._res.setEncoding("utf8"),this._res.on("data",(Y)=>{J+=Y}),this._res.once("end",()=>{try{$(JSON.parse(J))}catch(Y){Z(Y)}})})}}l4.NodeHttpClientResponse=m$});var l=z((o4)=>{Object.defineProperty(o4,"__esModule",{value:!0});o4.parseHeadersForFetch=o4.parseHttpHeaderAsNumber=o4.parseHttpHeaderAsString=o4.getAPIMode=o4.jsonStringifyRequestData=o4.concat=o4.createApiKeyAuthenticator=o4.detectAIAgent=o4.AI_AGENTS=o4.determineProcessUserAgentProperties=o4.validateInteger=o4.flattenAndStringify=o4.isObject=o4.emitWarning=o4.pascalToCamelCase=o4.callbackifyPromiseWithTimeout=o4.normalizeHeader=o4.normalizeHeaders=o4.removeNullish=o4.protoExtend=o4.getOptionsFromArgs=o4.getDataFromArgs=o4.extractUrlParams=o4.makeURLInterpolator=o4.queryStringifyRequestData=o4.isOptionsHash=void 0;var c$=["apiKey","idempotencyKey","stripeAccount","apiVersion","maxNetworkRetries","timeout","host","authenticator","stripeContext","headers","additionalHeaders","streaming"];function l$($){return $&&typeof $==="object"&&c$.some((Z)=>Object.prototype.hasOwnProperty.call($,Z))}o4.isOptionsHash=l$;function LK($){return zK($)}o4.queryStringifyRequestData=LK;function d4($){return encodeURIComponent($).replace(/!/g,"%21").replace(/\*/g,"%2A").replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/'/g,"%27").replace(/%5B/g,"[").replace(/%5D/g,"]")}function UK($){if($ instanceof Date)return Math.floor($.getTime()/1000).toString();if($===null)return"";return String($)}function zK($){let Z=[];function J(Y,X){if(X===void 0)return;if(X===null||typeof X!=="object"||X instanceof Date){Z.push(d4(Y)+"="+d4(UK(X)));return}if(Array.isArray(X)){for(let Q=0;Q<X.length;Q++)if(X[Q]!==void 0)J(Y+"["+Q+"]",X[Q]);return}for(let Q of Object.keys(X))J(Y+"["+Q+"]",X[Q])}if(typeof $==="object"&&$!==null)for(let Y of Object.keys($))J(Y,$[Y]);return Z.join("&")}o4.makeURLInterpolator=(()=>{let $={"\n":"\\n",'"':"\\\"","\u2028":"\\u2028","\u2029":"\\u2029"};return(Z)=>{let J=Z.replace(/["\n\r\u2028\u2029]/g,(Y)=>$[Y]);return(Y)=>{return J.replace(/\{([\s\S]+?)\}/g,(X,Q)=>{let G=Y[Q];if(KK(G))return encodeURIComponent(G);return""})}}})();function KK($){return["number","string","boolean"].includes(typeof $)}function HK($){let Z=$.match(/\{\w+\}/g);if(!Z)return[];return Z.map((J)=>J.replace(/[{}]/g,""))}o4.extractUrlParams=HK;function TK($){if(!Array.isArray($)||!$[0]||typeof $[0]!=="object")return{};if(!l$($[0]))return $.shift();let Z=Object.keys($[0]),J=Z.filter((Y)=>c$.includes(Y));if(J.length>0&&J.length!==Z.length)n$(`Options found in arguments (${J.join(", ")}). Did you mean to pass an options object? See https://github.com/stripe/stripe-node/wiki/Passing-Options.`);return{}}o4.getDataFromArgs=TK;function wK($){let Z={host:null,headers:{},settings:{},streaming:!1};if($.length>0){let J=$[$.length-1];if(typeof J==="string")Z.authenticator=u$($.pop());else if(l$(J)){let Y={...$.pop()},X=Object.keys(Y).filter((Q)=>!c$.includes(Q));if(X.length)n$(`Invalid options found (${X.join(", ")}); ignoring.`);if(Y.apiKey)Z.authenticator=u$(Y.apiKey);if(Y.idempotencyKey)Z.headers["Idempotency-Key"]=Y.idempotencyKey;if(Y.stripeAccount)Z.headers["Stripe-Account"]=Y.stripeAccount;if(Y.stripeContext){if(Z.headers["Stripe-Account"])throw Error("Can't specify both stripeAccount and stripeContext.");Z.headers["Stripe-Context"]=Y.stripeContext}if(Y.apiVersion)Z.headers["Stripe-Version"]=Y.apiVersion;if(Number.isInteger(Y.maxNetworkRetries))Z.settings.maxNetworkRetries=Y.maxNetworkRetries;if(Number.isInteger(Y.timeout))Z.settings.timeout=Y.timeout;if(Y.host)Z.host=Y.host;if(Y.authenticator){if(Y.apiKey)throw Error("Can't specify both apiKey and authenticator.");if(typeof Y.authenticator!=="function")throw Error("The authenticator must be a function receiving a request as the first parameter.");Z.authenticator=Y.authenticator}if(Y.headers)Object.assign(Z.headers,Y.headers);if(Y.additionalHeaders)Object.assign(Z.headers,Y.additionalHeaders);if(Y.streaming)Z.streaming=!0}}return Z}o4.getOptionsFromArgs=wK;function DK($){let Z=this,J=Object.prototype.hasOwnProperty.call($,"constructor")?$.constructor:function(...Y){Z.apply(this,Y)};return Object.assign(J,Z),J.prototype=Object.create(Z.prototype),Object.assign(J.prototype,$),J}o4.protoExtend=DK;function OK($){if(typeof $!=="object")throw Error("Argument must be an object");return Object.keys($).reduce((Z,J)=>{if($[J]!=null)Z[J]=$[J];return Z},{})}o4.removeNullish=OK;function qK($){if(!($&&typeof $==="object"))return $;return Object.keys($).reduce((Z,J)=>{return Z[i4(J)]=$[J],Z},{})}o4.normalizeHeaders=qK;function i4($){return $.split("-").map((Z)=>Z.charAt(0).toUpperCase()+Z.substr(1).toLowerCase()).join("-")}o4.normalizeHeader=i4;function EK($,Z){if(Z)return $.then((J)=>{setTimeout(()=>{Z(null,J)},0)},(J)=>{setTimeout(()=>{Z(J,null)},0)});return $}o4.callbackifyPromiseWithTimeout=EK;function CK($){if($==="OAuth")return"oauth";else return $[0].toLowerCase()+$.substring(1)}o4.pascalToCamelCase=CK;function n$($){if(typeof process.emitWarning!=="function")return console.warn(`Stripe: ${$}`);return process.emitWarning($,"Stripe")}o4.emitWarning=n$;function a4($){let Z=typeof $;return(Z==="function"||Z==="object")&&!!$}o4.isObject=a4;function FK($){let Z={},J=(Y,X)=>{Object.entries(Y).forEach(([Q,G])=>{let W=X?`${X}[${Q}]`:Q;if(a4(G))if(!(G instanceof Uint8Array)&&!Object.prototype.hasOwnProperty.call(G,"data"))return J(G,W);else Z[W]=G;else Z[W]=String(G)})};return J($,null),Z}o4.flattenAndStringify=FK;function kK($,Z,J){if(!Number.isInteger(Z))if(J!==void 0)return J;else throw Error(`${$} must be an integer`);return Z}o4.validateInteger=kK;function xK(){return typeof process>"u"?{}:{lang_version:process.version}}o4.determineProcessUserAgentProperties=xK;o4.AI_AGENTS=[["ANTIGRAVITY_CLI_ALIAS","antigravity"],["CLAUDECODE","claude_code"],["CLINE_ACTIVE","cline"],["CODEX_SANDBOX","codex_cli"],["CODEX_THREAD_ID","codex_cli"],["CODEX_SANDBOX_NETWORK_DISABLED","codex_cli"],["CODEX_CI","codex_cli"],["CURSOR_AGENT","cursor"],["GEMINI_CLI","gemini_cli"],["OPENCLAW_SHELL","openclaw"],["OPENCODE","open_code"]];function AK($){for(let[Z,J]of o4.AI_AGENTS)if($[Z])return J;return""}o4.detectAIAgent=AK;function u$($){let Z=(J)=>{return J.headers.Authorization="Bearer "+$,Promise.resolve()};return Z._apiKey=$,Z}o4.createApiKeyAuthenticator=u$;function NK($){let Z=$.reduce((X,Q)=>X+Q.length,0),J=new Uint8Array(Z),Y=0;return $.forEach((X)=>{J.set(X,Y),Y+=X.length}),J}o4.concat=NK;function IK($,Z){if(this[$]instanceof Date)return Math.floor(this[$].getTime()/1000).toString();return Z}function PK($){return JSON.stringify($,IK)}o4.jsonStringifyRequestData=PK;function vK($){if(!$)return"v1";return $.startsWith("/v2")?"v2":"v1"}o4.getAPIMode=vK;function s4($){if(Array.isArray($))return $.join(", ");return String($)}o4.parseHttpHeaderAsString=s4;function yK($){let Z=Array.isArray($)?$[0]:$;return Number(Z)}o4.parseHttpHeaderAsNumber=yK;function SK($){return Object.entries($).map(([Z,J])=>{return[Z,s4(J)]})}o4.parseHeadersForFetch=SK});var ZZ=z((e4)=>{Object.defineProperty(e4,"__esModule",{value:!0});e4.FetchHttpClientResponse=e4.FetchHttpClient=void 0;var JH=l(),h0=M0();class v8 extends h0.HttpClient{constructor($){super();if(!$){if(!globalThis.fetch)throw Error("fetch() function not provided and is not defined in the global scope. You must provide a fetch implementation.");$=globalThis.fetch}if(globalThis.AbortController)this._fetchFn=v8.makeFetchWithAbortTimeout($);else this._fetchFn=v8.makeFetchWithRaceTimeout($)}static makeFetchWithRaceTimeout($){return(Z,J,Y)=>{let X,Q=new Promise((W,L)=>{X=setTimeout(()=>{X=null,L(h0.HttpClient.makeTimeoutError())},Y)}),G=$(Z,J);return Promise.race([G,Q]).finally(()=>{if(X)clearTimeout(X)})}}static makeFetchWithAbortTimeout($){return async(Z,J,Y)=>{let X=new AbortController,Q=setTimeout(()=>{Q=null,X.abort(h0.HttpClient.makeTimeoutError())},Y);try{return await $(Z,{...J,signal:X.signal})}catch(G){if(G.name==="AbortError")throw h0.HttpClient.makeTimeoutError();else throw G}finally{if(Q)clearTimeout(Q)}}}getClientName(){return"fetch"}async makeRequest($,Z,J,Y,X,Q,G,W){let B=new URL(J,`${G==="http"?"http":"https"}://${$}`);B.port=Z;let V=Y=="POST"||Y=="PUT"||Y=="PATCH",U=Q||(V?"":void 0),K=await this._fetchFn(B.toString(),{method:Y,headers:(0,JH.parseHeadersForFetch)(X),body:U},W);return new y8(K)}}e4.FetchHttpClient=v8;class y8 extends h0.HttpClientResponse{constructor($){super($.status,y8._transformHeadersToObject($.headers));this._res=$}getRawResponse(){return this._res}toStream($){return $(),this._res.body}toJSON(){return this._res.json()}static _transformHeadersToObject($){let Z={};for(let J of $){if(!Array.isArray(J)||J.length!=2)throw Error("Response objects produced by the fetch function given to FetchHttpClient do not have an iterable headers map. Response#headers should be an iterable object.");Z[J[0]]=J[1]}return Z}}e4.FetchHttpClientResponse=y8});var GZ=z((XZ)=>{Object.defineProperty(XZ,"__esModule",{value:!0});XZ.SubtleCryptoProvider=void 0;var JZ=g0();class YZ extends JZ.CryptoProvider{constructor($){super();this.subtleCrypto=$||crypto.subtle}computeHMACSignature($,Z){throw new JZ.CryptoProviderOnlySupportsAsyncError("SubtleCryptoProvider cannot be used in a synchronous context.")}async computeHMACSignatureAsync($,Z){let J=new TextEncoder,Y=await this.subtleCrypto.importKey("raw",J.encode(Z),{name:"HMAC",hash:{name:"SHA-256"}},!1,["sign"]),X=await this.subtleCrypto.sign("hmac",Y,J.encode($)),Q=new Uint8Array(X),G=Array(Q.length);for(let W=0;W<Q.length;W++)G[W]=p$[Q[W]];return G.join("")}async computeSHA256Async($){return new Uint8Array(await this.subtleCrypto.digest("SHA-256",$))}}XZ.SubtleCryptoProvider=YZ;var p$=Array(256);for(let $=0;$<p$.length;$++)p$[$]=$.toString(16).padStart(2,"0")});var LZ=z((VZ)=>{Object.defineProperty(VZ,"__esModule",{value:!0});VZ.PlatformFunctions=void 0;var XH=ZZ(),QH=GZ();class WZ{constructor(){this._fetchFn=null,this._agent=null}getPlatformInfo(){return null}uuid4(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,($)=>{let Z=Math.random()*16|0;return($==="x"?Z:Z&3|8).toString(16)})}secureCompare($,Z){if($.length!==Z.length)return!1;let J=$.length,Y=0;for(let X=0;X<J;++X)Y|=$.charCodeAt(X)^Z.charCodeAt(X);return Y===0}createEmitter(){throw Error("createEmitter not implemented.")}tryBufferData($){throw Error("tryBufferData not implemented.")}createNodeHttpClient($){throw Error("createNodeHttpClient not implemented.")}createFetchHttpClient($){return new XH.FetchHttpClient($)}createDefaultHttpClient(){throw Error("createDefaultHttpClient not implemented.")}createNodeCryptoProvider(){throw Error("createNodeCryptoProvider not implemented.")}createSubtleCryptoProvider($){return new QH.SubtleCryptoProvider($)}createDefaultCryptoProvider(){throw Error("createDefaultCryptoProvider not implemented.")}}VZ.PlatformFunctions=WZ});var m0=z((KZ)=>{Object.defineProperty(KZ,"__esModule",{value:!0});KZ.TemporarySessionExpiredError=KZ.RecipientNotNotifiableError=KZ.RateLimitError=KZ.QuotaExceededError=KZ.NotCancelableError=KZ.NonZeroBalanceError=KZ.InvalidPayoutMethodError=KZ.InvalidPaymentMethodError=KZ.InsufficientFundsError=KZ.FinancialAccountNotOpenError=KZ.FeatureNotEnabledError=KZ.ControlledByDashboardError=KZ.ControlledByAlternateResourceError=KZ.BlockedByStripeError=KZ.AlreadyExistsError=KZ.AlreadyCanceledError=KZ.StripeUnsupportedResponseTypeError=KZ.StripeUnsupportedGrantTypeError=KZ.StripeInvalidScopeError=KZ.StripeOAuthInvalidRequestError=KZ.StripeInvalidClientError=KZ.StripeInvalidGrantError=KZ.StripeOAuthError=KZ.StripeIdempotencyError=KZ.StripeSignatureVerificationError=KZ.StripeConnectionError=KZ.StripeRateLimitError=KZ.StripePermissionError=KZ.StripeAuthenticationError=KZ.StripeAPIError=KZ.StripeInvalidRequestError=KZ.StripeCardError=KZ.StripeError=KZ.generateV2Error=KZ.generateOAuthError=KZ.generateV1Error=void 0;var GH=($)=>{let Z=$.statusCode;if(Z===429||Z===400&&$.code==="rate_limit")return new o$($);if(Z===400||Z===404){if($.type==="idempotency_error")return new R8($);return new S8($)}if(Z===401)return new a$($);if(Z===402)return new d$($);if(Z===403)return new s$($);return new i$($)};KZ.generateV1Error=GH;var WH=($)=>{switch($.type){case"invalid_grant":return new r$($);case"invalid_client":return new t$($);case"invalid_request":return new e$($);case"invalid_scope":return new $9($);case"unsupported_grant_type":return new Z9($);case"unsupported_response_type":return new J9($);default:return new d($)}};KZ.generateOAuthError=WH;var VH=($)=>{switch($.type){case"idempotency_error":return new R8($);case"already_canceled":return new Y9($);case"already_exists":return new X9($);case"blocked_by_stripe":return new Q9($);case"controlled_by_alternate_resource":return new G9($);case"controlled_by_dashboard":return new W9($);case"feature_not_enabled":return new V9($);case"financial_account_not_open":return new B9($);case"insufficient_funds":return new L9($);case"invalid_payment_method":return new U9($);case"invalid_payout_method":return new z9($);case"non_zero_balance":return new K9($);case"not_cancelable":return new H9($);case"quota_exceeded":return new T9($);case"rate_limit":return new w9($);case"recipient_not_notifiable":return new D9($);case"temporary_session_expired":return new O9($)}switch($.code){case"invalid_fields":return new S8($)}return KZ.generateV1Error($)};KZ.generateV2Error=VH;class A extends Error{constructor($={},Z=null){super($.message);this.type=Z||this.constructor.name,this.raw=$,this.rawType=$.type,this.code=$.code,this.doc_url=$.doc_url,this.param=$.param,this.detail=$.detail,this.headers=$.headers,this.requestId=$.requestId,this.statusCode=$.statusCode,this.message=$.message??"",this.userMessage=$.user_message,this.charge=$.charge,this.decline_code=$.decline_code,this.payment_intent=$.payment_intent,this.payment_method=$.payment_method,this.payment_method_type=$.payment_method_type,this.setup_intent=$.setup_intent,this.source=$.source}}KZ.StripeError=A;A.generate=KZ.generateV1Error;class d$ extends A{constructor($={}){super($,"StripeCardError")}}KZ.StripeCardError=d$;class S8 extends A{constructor($={}){super($,"StripeInvalidRequestError")}}KZ.StripeInvalidRequestError=S8;class i$ extends A{constructor($={}){super($,"StripeAPIError")}}KZ.StripeAPIError=i$;class a$ extends A{constructor($={}){super($,"StripeAuthenticationError")}}KZ.StripeAuthenticationError=a$;class s$ extends A{constructor($={}){super($,"StripePermissionError")}}KZ.StripePermissionError=s$;class o$ extends A{constructor($={}){super($,"StripeRateLimitError")}}KZ.StripeRateLimitError=o$;class UZ extends A{constructor($={}){super($,"StripeConnectionError")}}KZ.StripeConnectionError=UZ;class zZ extends A{constructor($,Z,J={}){super(J,"StripeSignatureVerificationError");this.header=$,this.payload=Z}}KZ.StripeSignatureVerificationError=zZ;class R8 extends A{constructor($={}){super($,"StripeIdempotencyError")}}KZ.StripeIdempotencyError=R8;class d extends A{constructor($={},Z="StripeOAuthError"){super($,Z)}}KZ.StripeOAuthError=d;class r$ extends d{constructor($={}){super($,"StripeInvalidGrantError")}}KZ.StripeInvalidGrantError=r$;class t$ extends d{constructor($={}){super($,"StripeInvalidClientError")}}KZ.StripeInvalidClientError=t$;class e$ extends d{constructor($={}){super($,"StripeOAuthInvalidRequestError")}}KZ.StripeOAuthInvalidRequestError=e$;class $9 extends d{constructor($={}){super($,"StripeInvalidScopeError")}}KZ.StripeInvalidScopeError=$9;class Z9 extends d{constructor($={}){super($,"StripeUnsupportedGrantTypeError")}}KZ.StripeUnsupportedGrantTypeError=Z9;class J9 extends d{constructor($={}){super($,"StripeUnsupportedResponseTypeError")}}KZ.StripeUnsupportedResponseTypeError=J9;class Y9 extends A{constructor($={}){super($,"AlreadyCanceledError")}}KZ.AlreadyCanceledError=Y9;class X9 extends A{constructor($={}){super($,"AlreadyExistsError")}}KZ.AlreadyExistsError=X9;class Q9 extends A{constructor($={}){super($,"BlockedByStripeError")}}KZ.BlockedByStripeError=Q9;class G9 extends A{constructor($={}){super($,"ControlledByAlternateResourceError")}}KZ.ControlledByAlternateResourceError=G9;class W9 extends A{constructor($={}){super($,"ControlledByDashboardError")}}KZ.ControlledByDashboardError=W9;class V9 extends A{constructor($={}){super($,"FeatureNotEnabledError")}}KZ.FeatureNotEnabledError=V9;class B9 extends A{constructor($={}){super($,"FinancialAccountNotOpenError")}}KZ.FinancialAccountNotOpenError=B9;class L9 extends A{constructor($={}){super($,"InsufficientFundsError")}}KZ.InsufficientFundsError=L9;class U9 extends A{constructor($){super($,"InvalidPaymentMethodError");this.invalid_param=this.raw.invalid_param}}KZ.InvalidPaymentMethodError=U9;class z9 extends A{constructor($={}){super($,"InvalidPayoutMethodError")}}KZ.InvalidPayoutMethodError=z9;class K9 extends A{constructor($={}){super($,"NonZeroBalanceError")}}KZ.NonZeroBalanceError=K9;class H9 extends A{constructor($={}){super($,"NotCancelableError")}}KZ.NotCancelableError=H9;class T9 extends A{constructor($={}){super($,"QuotaExceededError")}}KZ.QuotaExceededError=T9;class w9 extends A{constructor($={}){super($,"RateLimitError")}}KZ.RateLimitError=w9;class D9 extends A{constructor($={}){super($,"RecipientNotNotifiableError")}}KZ.RecipientNotNotifiableError=D9;class O9 extends A{constructor($={}){super($,"TemporarySessionExpiredError")}}KZ.TemporarySessionExpiredError=O9});var FZ=z((EZ)=>{Object.defineProperty(EZ,"__esModule",{value:!0});EZ.NodePlatformFunctions=void 0;var b8=q("crypto"),TZ=q("events"),lH=j4(),wZ=p4(),nH=LZ(),pH=m0(),dH=l(),DZ=q("os");class OZ extends pH.StripeError{}class qZ extends nH.PlatformFunctions{uuid4(){if(b8.randomUUID)return b8.randomUUID();return super.uuid4()}getPlatformInfo(){return`${process.platform} ${(0,DZ.release)()} ${(0,DZ.arch)()}`}secureCompare($,Z){if(!$||!Z)throw Error("secureCompare must receive two arguments");if($.length!==Z.length)return!1;if(b8.timingSafeEqual){let J=new TextEncoder,Y=J.encode($),X=J.encode(Z);return b8.timingSafeEqual(Y,X)}return super.secureCompare($,Z)}createEmitter(){return new TZ.EventEmitter}tryBufferData($){if(!($.file.data instanceof TZ.EventEmitter))return Promise.resolve($);let Z=[];return new Promise((J,Y)=>{$.file.data.on("data",(X)=>{Z.push(X)}).once("end",()=>{let X=Object.assign({},$);X.file.data=(0,dH.concat)(Z),J(X)}).on("error",(X)=>{Y(new OZ({message:"An error occurred while attempting to process the file for upload.",detail:X}))})})}createNodeHttpClient($){return new wZ.NodeHttpClient($)}createDefaultHttpClient(){return new wZ.NodeHttpClient}createNodeCryptoProvider(){return new lH.NodeCryptoProvider}createDefaultCryptoProvider(){return this.createNodeCryptoProvider()}}EZ.NodePlatformFunctions=qZ});var NZ=z((xZ)=>{Object.defineProperty(xZ,"__esModule",{value:!0});xZ.RequestSender=void 0;var O0=m0(),kZ=M0(),f=l(),iH=60;class u0{constructor($,Z){this._stripe=$,this._maxBufferedRequestMetric=Z}_normalizeStripeContext($,Z){if($)return $.toString()||null;return Z?.toString()||null}_addHeadersDirectlyToObject($,Z){$.requestId=Z["request-id"],$.stripeAccount=$.stripeAccount||Z["stripe-account"],$.apiVersion=$.apiVersion||Z["stripe-version"],$.idempotencyKey=$.idempotencyKey||Z["idempotency-key"]}_makeResponseEvent($,Z,J){let Y=Date.now(),X=Y-$.request_start_time;return(0,f.removeNullish)({api_version:J["stripe-version"],account:J["stripe-account"],idempotency_key:J["idempotency-key"],method:$.method,path:$.path,status:Z,request_id:this._getRequestId(J),elapsed:X,request_start_time:$.request_start_time,request_end_time:Y})}_getRequestId($){return $["request-id"]}_streamingResponseHandler($,Z,J){return(Y)=>{let X=Y.getHeaders(),Q=()=>{let W=this._makeResponseEvent($,Y.getStatusCode(),X);this._stripe._emitter.emit("response",W),this._recordRequestMetrics(this._getRequestId(X),W.elapsed,Z)},G=Y.toStream(Q);return this._addHeadersDirectlyToObject(G,X),J(null,G)}}_jsonResponseHandler($,Z,J,Y){return(X)=>{let Q=X.getHeaders(),G=this._getRequestId(Q),W=X.getStatusCode(),L=this._makeResponseEvent($,W,Q);this._stripe._emitter.emit("response",L),X.toJSON().then((B)=>{if(B.error){let V=typeof B.error==="string";if(V)B.error={type:B.error,message:B.error_description};B.error.headers=Q,B.error.statusCode=W,B.error.requestId=G;let U;if(V)U=(0,O0.generateOAuthError)(B.error);else if(Z==="v2")U=(0,O0.generateV2Error)(B.error);else U=(0,O0.generateV1Error)(B.error);throw U}return B},(B)=>{throw new O0.StripeAPIError({message:"Invalid JSON received from the Stripe API",exception:B,requestId:Q["request-id"]})}).then((B)=>{this._recordRequestMetrics(G,L.elapsed,J);let V=X.getRawResponse();this._addHeadersDirectlyToObject(V,Q),Object.defineProperty(B,"lastResponse",{enumerable:!1,writable:!1,value:V}),Y(null,B)},(B)=>Y(B,null))}}static _generateConnectionErrorMessage($){return`An error occurred with our connection to Stripe.${$>0?` Request was retried ${$} times.`:""}`}static _shouldRetry($,Z,J,Y){if(Y&&Z===0&&kZ.HttpClient.CONNECTION_CLOSED_ERROR_CODES.includes(Y.code))return!0;if(Z>=J)return!1;if(!$)return!0;if($.getHeaders()["stripe-should-retry"]==="false")return!1;if($.getHeaders()["stripe-should-retry"]==="true")return!0;if($.getStatusCode()===409)return!0;if($.getStatusCode()>=500)return!0;return!1}_getSleepTimeInMS($,Z=null){let J=this._stripe.getInitialNetworkRetryDelay(),Y=this._stripe.getMaxNetworkRetryDelay(),X=Math.min(J*Math.pow(2,$-1),Y);if(X*=0.5*(1+Math.random()),X=Math.max(J,X),Number.isInteger(Z)&&Z<=iH)X=Math.max(X,Z);return X*1000}_getMaxNetworkRetries($={}){return $.maxNetworkRetries!==void 0&&Number.isInteger($.maxNetworkRetries)?$.maxNetworkRetries:this._stripe.getMaxNetworkRetries()}_defaultIdempotencyKey($,Z,J){let Y=this._getMaxNetworkRetries(Z),X=()=>`stripe-node-retry-${this._stripe._platformFunctions.uuid4()}`;if(J==="v2"){if($==="POST"||$==="DELETE")return X()}else if(J==="v1"){if($==="POST"&&Y>0)return X()}return null}_makeHeaders({contentType:$,contentLength:Z,apiVersion:J,clientUserAgent:Y,method:X,userSuppliedHeaders:Q,userSuppliedSettings:G,stripeAccount:W,stripeContext:L,apiMode:B}){let V={Accept:"application/json","Content-Type":$,"User-Agent":this._getUserAgentString(B),"X-Stripe-Client-User-Agent":Y,"X-Stripe-Client-Telemetry":this._getTelemetryHeader(),"Stripe-Version":J,"Stripe-Account":W,"Stripe-Context":L,"Idempotency-Key":this._defaultIdempotencyKey(X,G,B)},U=X=="POST"||X=="PUT"||X=="PATCH";if(U||Z){if(!U)(0,f.emitWarning)(`${X} method had non-zero contentLength but no payload is expected for this verb`);V["Content-Length"]=Z}return Object.assign((0,f.removeNullish)(V),(0,f.normalizeHeaders)(Q))}_getUserAgentString($){let Z=this._stripe.getConstant("PACKAGE_VERSION"),J=this._stripe._appInfo?this._stripe.getAppInfoAsString():"",Y=this._stripe.getConstant("AI_AGENT"),X=`Stripe/${$} NodeBindings/${Z}`;if(J)X+=` ${J}`;if(Y)X+=` AIAgent/${Y}`;return X}_getTelemetryHeader(){if(this._stripe.getTelemetryEnabled()&&this._stripe._prevRequestMetrics.length>0){let $=this._stripe._prevRequestMetrics.shift();return JSON.stringify({last_request_metrics:$})}}_recordRequestMetrics($,Z,J){if(this._stripe.getTelemetryEnabled()&&$)if(this._stripe._prevRequestMetrics.length>this._maxBufferedRequestMetric)(0,f.emitWarning)("Request metrics buffer is full, dropping telemetry message.");else{let Y={request_id:$,request_duration_ms:Z};if(J&&J.length>0)Y.usage=J;this._stripe._prevRequestMetrics.push(Y)}}_rawRequest($,Z,J,Y,X){return new Promise((G,W)=>{let L;try{let T=$.toUpperCase();if(T!=="POST"&&J&&Object.keys(J).length!==0)throw Error("rawRequest only supports params on POST requests. Please pass null and add your parameters to path.");let w=[].slice.call([J,Y]),D=(0,f.getDataFromArgs)(w),C=T==="POST"?Object.assign({},D):null,E=(0,f.getOptionsFromArgs)(w),k=E.headers,I=E.authenticator;L={requestMethod:T,requestPath:Z,bodyData:C,queryData:{},authenticator:I,headers:k,host:E.host,streaming:!!E.streaming,settings:{},usage:X||["raw_request"]}}catch(T){W(T);return}function B(T,w){if(T)W(T);else G(w)}let{headers:V,settings:U}=L,K=L.authenticator;this._request(L.requestMethod,L.host,Z,L.bodyData,K,{headers:V,settings:U,streaming:L.streaming},L.usage,B)})}_getContentLength($){return typeof $==="string"?new TextEncoder().encode($).length:$.length}_request($,Z,J,Y,X,Q,G=[],W,L=null){let B;X=X??this._stripe._authenticator??null;let V=(0,f.getAPIMode)(J),U=(w,D,C,E,k)=>{return setTimeout(w,this._getSleepTimeInMS(E,k),D,C,E+1)},K=(w,D,C)=>{let E=Q.settings&&Q.settings.timeout&&Number.isInteger(Q.settings.timeout)&&Q.settings.timeout>=0?Q.settings.timeout:this._stripe.getApiField("timeout"),k={host:Z||this._stripe.getApiField("host"),port:this._stripe.getApiField("port"),path:J,method:$,headers:Object.assign({},D),body:B,protocol:this._stripe.getApiField("protocol")};X(k).then(()=>{let I=this._stripe.getApiField("httpClient").makeRequest(k.host,k.port,k.path,k.method,k.headers,k.body,k.protocol,E),R=Date.now(),M=(0,f.removeNullish)({api_version:w,account:(0,f.parseHttpHeaderAsString)(D["Stripe-Account"]),idempotency_key:(0,f.parseHttpHeaderAsString)(D["Idempotency-Key"]),method:$,path:J,request_start_time:R}),h=C||0,R0=this._getMaxNetworkRetries(Q.settings||{});this._stripe._emitter.emit("request",M),I.then((b)=>{if(u0._shouldRetry(b,h,R0))return U(K,w,D,h,(0,f.parseHttpHeaderAsNumber)(b.getHeaders()["retry-after"]));else if(Q.streaming&&b.getStatusCode()<400)return this._streamingResponseHandler(M,G,W)(b);else return this._jsonResponseHandler(M,V,G,W)(b)}).catch((b)=>{if(u0._shouldRetry(null,h,R0,b))return U(K,w,D,h,null);else{let kz=b.code&&b.code===kZ.HttpClient.TIMEOUT_ERROR_CODE;return W(new O0.StripeConnectionError({message:kz?`Request aborted due to timeout being reached (${E}ms)`:u0._generateConnectionErrorMessage(h),detail:b}))}})}).catch((I)=>{throw new O0.StripeError({message:"Unable to authenticate the request",exception:I})})},T=(w,D)=>{if(w)return W(w);B=D,this._stripe.getClientUserAgent((C)=>{let E=this._stripe.getApiField("version"),k=this._makeHeaders({contentType:V=="v2"?"application/json":"application/x-www-form-urlencoded",contentLength:this._getContentLength(D),apiVersion:E,clientUserAgent:C,method:$,userSuppliedHeaders:Q.headers??null,userSuppliedSettings:Q.settings??{},stripeAccount:Q.stripeAccount??this._stripe.getApiField("stripeAccount"),stripeContext:this._normalizeStripeContext(Q.stripeContext,this._stripe.getApiField("stripeContext")),apiMode:V});K(E,k,0)})};if(L)L($,Y,Q.headers,T);else{let w;if(V=="v2")w=Y?(0,f.jsonStringifyRequestData)(Y):"";else w=(0,f.queryStringifyRequestData)(Y||{});T(null,w)}}}xZ.RequestSender=u0});var bZ=z((SZ)=>{Object.defineProperty(SZ,"__esModule",{value:!0});SZ.makeAutoPaginationMethods=void 0;var j8=l();class C9{constructor($,Z,J,Y){this.index=0,this.pagePromise=$,this.promiseCache={currentPromise:null},this.requestArgs=Z,this.spec=J,this.stripeResource=Y}async iterate($){if(!($&&$.data&&typeof $.data.length==="number"))throw Error("Unexpected: Stripe API response does not have a well-formed `data` array.");let Z=yZ(this.requestArgs);if(this.index<$.data.length){let J=Z?$.data.length-1-this.index:this.index,Y=$.data[J];return this.index+=1,{value:Y,done:!1}}else if($.has_more){this.index=0,this.pagePromise=this.getNextPage($);let J=await this.pagePromise;return this.iterate(J)}return{done:!0,value:void 0}}getNextPage($){throw Error("Unimplemented")}async _next(){return this.iterate(await this.pagePromise)}next(){if(this.promiseCache.currentPromise)return this.promiseCache.currentPromise;let $=(async()=>{let Z=await this._next();return this.promiseCache.currentPromise=null,Z})();return this.promiseCache.currentPromise=$,$}}class IZ extends C9{getNextPage($){let Z=yZ(this.requestArgs),J=tH($,Z);return this.stripeResource._makeRequest(this.requestArgs,this.spec,{[Z?"ending_before":"starting_after"]:J})}}class PZ extends C9{getNextPage($){if(!$.next_page)throw Error("Unexpected: Stripe API response does not have a well-formed `next_page` field, but `has_more` was true.");return this.stripeResource._makeRequest(this.requestArgs,this.spec,{page:$.next_page})}}class vZ{constructor($,Z,J,Y){this.firstPagePromise=$,this.currentPageIterator=null,this.nextPageUrl=null,this.requestArgs=Z,this.spec=J,this.stripeResource=Y}async initFirstPage(){if(this.firstPagePromise){let $=await this.firstPagePromise;this.firstPagePromise=null,this.currentPageIterator=$.data[Symbol.iterator](),this.nextPageUrl=$.next_page_url||null}}async turnPage(){if(!this.nextPageUrl)return null;this.spec.fullPath=this.nextPageUrl;let $=await this.stripeResource._makeRequest([],this.spec,{});return this.nextPageUrl=$.next_page_url||null,this.currentPageIterator=$.data[Symbol.iterator](),this.currentPageIterator}async next(){if(await this.initFirstPage(),this.currentPageIterator){let J=this.currentPageIterator.next();if(!J.done)return{done:!1,value:J.value}}let $=await this.turnPage();if(!$)return{done:!0,value:void 0};let Z=$.next();if(!Z.done)return{done:!1,value:Z.value};return{done:!0,value:void 0}}}var aH=($,Z,J,Y)=>{let X=(0,j8.getAPIMode)(J.fullPath||J.path);if(X!=="v2"&&J.methodType==="search")return E9(new PZ(Y,Z,J,$));if(X!=="v2"&&J.methodType==="list")return E9(new IZ(Y,Z,J,$));if(X==="v2"&&J.methodType==="list")return E9(new vZ(Y,Z,J,$));return null};SZ.makeAutoPaginationMethods=aH;var E9=($)=>{let Z=eH((...X)=>$.next(...X)),J=$T(Z),Y={autoPagingEach:Z,autoPagingToArray:J,next:()=>$.next(),return:()=>{return{}},[sH()]:()=>{return Y}};return Y};function sH(){if(typeof Symbol<"u"&&Symbol.asyncIterator)return Symbol.asyncIterator;return"@@asyncIterator"}function oH($){if($.length<2)return null;let Z=$[1];if(typeof Z!=="function")throw Error(`The second argument to autoPagingEach, if present, must be a callback function; received ${typeof Z}`);return Z}function rH($){if($.length===0)return;let Z=$[0];if(typeof Z!=="function")throw Error(`The first argument to autoPagingEach, if present, must be a callback function; received ${typeof Z}`);if(Z.length===2)return Z;if(Z.length>2)throw Error(`The \`onItem\` callback function passed to autoPagingEach must accept at most two arguments; got ${Z}`);return function(Y,X){let Q=Z(Y);X(Q)}}function tH($,Z){let J=Z?0:$.data.length-1,Y=$.data[J],X=Y&&Y.id;if(!X)throw Error("Unexpected: No `id` found on the last item while auto-paging a list.");return X}function eH($){return function(){let J=[].slice.call(arguments),Y=rH(J),X=oH(J);if(J.length>2)throw Error(`autoPagingEach takes up to two arguments; received ${J}`);let Q=ZT($,Y);return(0,j8.callbackifyPromiseWithTimeout)(Q,X)}}function $T($){return function(J,Y){let X=J&&J.limit;if(!X)throw Error("You must pass a `limit` option to autoPagingToArray, e.g., `autoPagingToArray({limit: 1000});`.");if(X>1e4)throw Error("You cannot specify a limit of more than 10,000 items to fetch in `autoPagingToArray`; use `autoPagingEach` to iterate through longer lists.");let Q=new Promise((G,W)=>{let L=[];$((B)=>{if(L.push(B),L.length>=X)return!1}).then(()=>{G(L)}).catch(W)});return(0,j8.callbackifyPromiseWithTimeout)(Q,Y)}}function ZT($,Z){return new Promise((J,Y)=>{function X(Q){if(Q.done){J();return}let G=Q.value;return new Promise((W)=>{Z(G,W)}).then((W)=>{if(W===!1)return X({done:!0,value:void 0});else return $().then(X)})}$().then(X).catch(Y)})}function yZ($){let Z=[].slice.call($);return!!(0,j8.getDataFromArgs)(Z).ending_before}});var gZ=z((fZ)=>{Object.defineProperty(fZ,"__esModule",{value:!0});fZ.stripeMethod=void 0;var jZ=l(),JT=bZ();function YT($){if($.path!==void 0&&$.fullPath!==void 0)throw Error(`Method spec specified both a 'path' (${$.path}) and a 'fullPath' (${$.fullPath}).`);return function(...Z){let J=typeof Z[Z.length-1]=="function"&&Z.pop();$.urlParams=(0,jZ.extractUrlParams)($.fullPath||this.createResourcePathWithSymbols($.path||""));let Y=(0,jZ.callbackifyPromiseWithTimeout)(this._makeRequest(Z,$,{}),J);return Object.assign(Y,(0,JT.makeAutoPaginationMethods)(this,Z,$,Y)),Y}}fZ.stripeMethod=YT});var F9=z((hZ)=>{Object.defineProperty(hZ,"__esModule",{value:!0});hZ.Decimal=hZ.isDecimal=hZ.DEFAULT_DIV_PRECISION=void 0;var XT={"ubb-usage-count":{mode:"significant-figures",value:15},"v1-api":{mode:"decimal-places",value:12}};hZ.DEFAULT_DIV_PRECISION=34;var MZ=30,f8=1e6;class v{constructor($,Z){let[J,Y]=v.normalize($,Z);this._coefficient=J,this._exponent=Y,Object.freeze(this)}static normalize($,Z){if($===0n)return[0n,0];let J=$,Y=Z;while(J!==0n&&J%10n===0n)J/=10n,Y+=1;return[J,Y]}static roundDivision($,Z,J,Y){if(Z===0n)return $;if(Y==="round-down")return $;let X=Z>0n===J>0n?1n:-1n;if(Y==="round-up")return $+X;if(Y==="ceil")return X===1n?$+1n:$;if(Y==="floor")return X===-1n?$-1n:$;let Q=Z<0n?-Z:Z,G=J<0n?-J:J,W=Q*2n,L;if(W===G)L=0;else if(W<G)L=-1;else L=1;if(L<0)return $;if(L>0)return $+X;if(Y==="half-up")return $+X;if(Y==="half-down")return $;if($%2n===0n)return $;else return $+X}add($){let Z=$;if(this._exponent===Z._exponent)return new v(this._coefficient+Z._coefficient,this._exponent);if(this._exponent<Z._exponent){let J=10n**BigInt(Z._exponent-this._exponent);return new v(this._coefficient+Z._coefficient*J,this._exponent)}else{let J=10n**BigInt(this._exponent-Z._exponent);return new v(this._coefficient*J+Z._coefficient,Z._exponent)}}sub($){let Z=$;if(this._exponent===Z._exponent)return new v(this._coefficient-Z._coefficient,this._exponent);if(this._exponent<Z._exponent){let J=10n**BigInt(Z._exponent-this._exponent);return new v(this._coefficient-Z._coefficient*J,this._exponent)}else{let J=10n**BigInt(this._exponent-Z._exponent);return new v(this._coefficient*J-Z._coefficient,Z._exponent)}}mul($){let Z=$;return new v(this._coefficient*Z._coefficient,this._exponent+Z._exponent)}div($,Z,J){if(Z<0||!Number.isInteger(Z))throw Error("precision must be a non-negative integer");let Y=$;if(Y._coefficient===0n)throw Error("Division by zero");let X=this._exponent-Y._exponent+Z,Q,G,W;if(X>=0){let B=this._coefficient*10n**BigInt(X);Q=B/Y._coefficient,G=B%Y._coefficient,W=Y._coefficient}else{let B=Y._coefficient*10n**BigInt(-X);Q=this._coefficient/B,G=this._coefficient%B,W=B}let L=v.roundDivision(Q,G,W,J);return new v(L,-Z)}cmp($){let Z=$;if(this._exponent===Z._exponent){if(this._coefficient<Z._coefficient)return-1;if(this._coefficient>Z._coefficient)return 1;return 0}if(this._exponent<Z._exponent){let J=10n**BigInt(Z._exponent-this._exponent),Y=Z._coefficient*J;if(this._coefficient<Y)return-1;if(this._coefficient>Y)return 1;return 0}else{let J=10n**BigInt(this._exponent-Z._exponent),Y=this._coefficient*J;if(Y<Z._coefficient)return-1;if(Y>Z._coefficient)return 1;return 0}}eq($){return this.cmp($)===0}lt($){return this.cmp($)===-1}lte($){return this.cmp($)<=0}gt($){return this.cmp($)===1}gte($){return this.cmp($)>=0}isZero(){return this._coefficient===0n}isNegative(){return this._coefficient<0n}isPositive(){return this._coefficient>0n}neg(){return new v(-this._coefficient,this._exponent)}abs(){if(this._coefficient<0n)return new v(-this._coefficient,this._exponent);return this}round($,Z){let J=typeof Z==="string"?XT[Z]:Z;if(J===void 0)throw Error(`Unknown rounding preset: "${Z}"`);if(J.value<0||!Number.isInteger(J.value))throw Error("DecimalRoundingOptions.value must be a non-negative integer");if(J.mode==="decimal-places"){let V=this.toFixed(J.value,$);return hZ.Decimal.from(V)}if(this._coefficient===0n)return this;let X=(this._coefficient<0n?(-this._coefficient).toString():this._coefficient.toString()).length;if(J.value===0)return hZ.Decimal.zero;if(X<=J.value)return this;let Q=X-J.value,G=10n**BigInt(Q),W=this._coefficient/G,L=this._coefficient%G,B=v.roundDivision(W,L,G,$);return new v(B,this._exponent+Q)}toString(){if(this._coefficient===0n)return"0";let $=this._coefficient.toString(),Z=$.startsWith("-"),J=Z?$.slice(1):$;if(this._exponent<0){let X=-this._exponent;if((X>=J.length?X-J.length:0)>MZ){if(J.length===1)return`${$}E${String(this._exponent)}`;let G=J[0]??"",W=J.slice(1),L=this._exponent+J.length-1;return`${Z?"-":""}${G}.${W}E${String(L)}`}if(X>=J.length){let G="0".repeat(X-J.length);return`${Z?"-":""}0.${G}${J}`}else{let G=J.slice(0,J.length-X),W=J.slice(J.length-X);return`${Z?"-":""}${G}.${W}`}}if(J.length+this._exponent<=MZ){if(this._exponent===0)return $;let X="0".repeat(this._exponent);return`${Z?"-":""}${J}${X}`}else{if(J.length===1)return`${$}E+${String(this._exponent)}`;let X=J[0]??"",Q=J.slice(1),G=this._exponent+J.length-1;return`${Z?"-":""}${X}.${Q}E+${String(G)}`}}toJSON(){return this.toString()}toNumber(){return Number(this.toString())}toFixed($,Z){if($<0||!Number.isInteger($))throw Error("decimalPlaces must be a non-negative integer");let J=(X)=>{let Q=X.toString(),G=Q.startsWith("-"),W=G?Q.slice(1):Q;if($===0)return Q;if($>=W.length){let L="0".repeat($-W.length);return`${G?"-":""}0.${L}${W}`}else{let L=W.slice(0,W.length-$),B=W.slice(W.length-$);return`${G?"-":""}${L}.${B}`}},Y=-$;if(this._exponent===Y)return J(this._coefficient);if(this._exponent<Y){let X=Y-this._exponent,Q=10n**BigInt(X),G=this._coefficient/Q,W=this._coefficient%Q,L=v.roundDivision(G,W,Q,Z);return J(L)}else{let X=this._exponent-Y,Q=this._coefficient*10n**BigInt(X);return J(Q)}}valueOf(){return this.toString()}}function QT($){return $ instanceof v}hZ.isDecimal=QT;hZ.Decimal={from($){if(typeof $==="bigint")return new v($,0);if(typeof $==="number"){if(!Number.isFinite($))throw Error("Number must be finite");return hZ.Decimal.from($.toString())}let Z=$.trim();if(Z==="")throw Error("Cannot parse empty string as Decimal");let J=/^([+-]?)(\d+)(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/.exec(Z);if(!J)throw Error(`Invalid decimal string: ${$}`);let Y=J[1]==="-"?-1n:1n,X=J[2]??"",Q=J[3]??"",G=J[4]?Number(J[4]):0;if(!Number.isSafeInteger(G)||G>f8||G<-f8)throw Error(`Exponent out of range: ${String(J[4])} exceeds safe integer bounds`);let W=X+Q,L=Y*BigInt(W),B=G-Q.length;if(!Number.isSafeInteger(B)||B>f8||B<-f8)throw Error(`Computed exponent out of range: ${String(B)} exceeds safe integer bounds`);return new v(L,B)},zero:new v(0n,0)}});var uZ=z((mZ)=>{Object.defineProperty(mZ,"__esModule",{value:!0});mZ.coerceV2ResponseData=mZ.coerceV2RequestData=void 0;var VT=F9(),BT=($,Z)=>{if($==null)return $;switch(Z.kind){case"int64_string":return typeof $==="bigint"||typeof $==="number"?String($):$;case"decimal_string":return typeof $.toFixed==="function"&&typeof $.isZero==="function"?$.toString():$;case"object":{if(typeof $!=="object"||Array.isArray($))return $;let J=$,Y={};for(let X of Object.keys(J)){let Q=Z.fields[X];Y[X]=Q?mZ.coerceV2RequestData(J[X],Q):J[X]}return Y}case"array":{if(!Array.isArray($))return $;return $.map((J)=>mZ.coerceV2RequestData(J,Z.element))}case"nullable":return mZ.coerceV2RequestData($,Z.inner)}};mZ.coerceV2RequestData=BT;var LT=($,Z)=>{if($==null)return $;switch(Z.kind){case"int64_string":if(typeof $==="string")try{return BigInt($)}catch{throw Error(`Failed to coerce int64_string value: expected an integer string, got '${$}'`)}return $;case"decimal_string":if(typeof $==="string")try{return VT.Decimal.from($)}catch{throw Error(`Failed to coerce decimal_string value: expected a decimal string, got '${$}'`)}return $;case"object":{if(typeof $!=="object"||Array.isArray($))return $;let J=$;for(let Y of Object.keys(Z.fields))if(Y in J)J[Y]=mZ.coerceV2ResponseData(J[Y],Z.fields[Y]);return J}case"array":{if(!Array.isArray($))return $;for(let J=0;J<$.length;J++)$[J]=mZ.coerceV2ResponseData($[J],Z.element);return $}case"nullable":return mZ.coerceV2ResponseData($,Z.inner)}};mZ.coerceV2ResponseData=LT});var H=z((lZ)=>{Object.defineProperty(lZ,"__esModule",{value:!0});lZ.StripeResource=void 0;var X0=l(),UT=gZ(),cZ=uZ();n0.extend=X0.protoExtend;n0.method=UT.stripeMethod;n0.MAX_BUFFERED_REQUEST_METRICS=100;function n0($,Z){if(this._stripe=$,Z)throw Error("Support for curried url params was dropped in stripe-node v7.0.0. Instead, pass two ids.");this.basePath=(0,X0.makeURLInterpolator)(this.basePath||$.getApiField("basePath")),this.resourcePath=this.path,this.path=(0,X0.makeURLInterpolator)(this.path),this.initialize(...arguments)}lZ.StripeResource=n0;n0.prototype={_stripe:null,path:"",resourcePath:"",basePath:null,initialize(){},requestDataProcessor:null,validateRequest:null,createFullPath($,Z){let J=[this.basePath(Z),this.path(Z)];if(typeof $==="function"){let Y=$(Z);if(Y)J.push(Y)}else J.push($);return this._joinUrlParts(J)},createResourcePathWithSymbols($){if($)return`/${this._joinUrlParts([this.resourcePath,$])}`;else return`/${this.resourcePath}`},_joinUrlParts($){return $.join("/").replace(/\/{2,}/g,"/")},_getRequestOpts($,Z,J){let Y=(Z.method||"GET").toUpperCase(),X=Z.usage||[],Q=Z.urlParams||[],G=Z.encode||((h)=>h),W=!!Z.fullPath,L=(0,X0.makeURLInterpolator)(W?Z.fullPath:Z.path||""),B=W?Z.fullPath:this.createResourcePathWithSymbols(Z.path),V=[].slice.call($),U=Q.reduce((h,R0)=>{let b=V.shift();if(typeof b!=="string")throw Error(`Stripe: Argument "${R0}" must be a string, but got: ${b} (on API request to \`${Y} ${B}\`)`);return h[R0]=b,h},{}),K=(0,X0.getDataFromArgs)(V),T=G(Object.assign({},K,J)),w=(0,X0.getOptionsFromArgs)(V),D=w.host||Z.host,C=!!Z.streaming||!!w.streaming;if(V.filter((h)=>h!=null).length)throw Error(`Stripe: Unknown arguments (${V}). Did you mean to pass an options object? See https://github.com/stripe/stripe-node/wiki/Passing-Options. (on API request to ${Y} \`${B}\`)`);let E=W?L(U):this.createFullPath(L,U),k=Object.assign(w.headers,Z.headers);if(Z.validator)Z.validator(T,{headers:k});let I=Z.method==="GET"||Z.method==="DELETE";return{requestMethod:Y,requestPath:E,bodyData:I?null:T,queryData:I?T:{},authenticator:w.authenticator??null,headers:k,host:D??null,streaming:C,settings:w.settings,usage:X}},_makeRequest($,Z,J){return new Promise((Y,X)=>{let Q;try{Q=this._getRequestOpts($,Z,J)}catch(U){X(U);return}if(Z.requestSchema&&Q.bodyData)Q.bodyData=(0,cZ.coerceV2RequestData)(Q.bodyData,Z.requestSchema);function G(U,K){if(U)X(U);else try{if(Z.responseSchema)(0,cZ.coerceV2ResponseData)(K,Z.responseSchema);Y(Z.transformResponseData?Z.transformResponseData(K):K)}catch(T){X(T)}}let W=Object.keys(Q.queryData).length===0,L=[Q.requestPath,W?"":"?",(0,X0.queryStringifyRequestData)(Q.queryData)].join(""),{headers:B,settings:V}=Q;this._stripe._requestSender._request(Q.requestMethod,Q.host,L,Q.bodyData,Q.authenticator,{headers:B,settings:V,streaming:Q.streaming},Q.usage,G,this.requestDataProcessor?.bind(this))})}}});var iZ=z((pZ)=>{Object.defineProperty(pZ,"__esModule",{value:!0});pZ.StripeContext=void 0;class q0{constructor($=[]){this._segments=[...$]}get segments(){return[...this._segments]}push($){if(!$)throw Error("Segment cannot be null or undefined");return new q0([...this._segments,$])}pop(){if(this._segments.length===0)throw Error("Cannot pop from an empty context");return new q0(this._segments.slice(0,-1))}toString(){return this._segments.join("/")}static parse($){if(!$)return new q0([]);return new q0($.split("/"))}}pZ.StripeContext=q0});var oZ=z((aZ)=>{Object.defineProperty(aZ,"__esModule",{value:!0});aZ.createWebhooks=void 0;var s=m0(),zT=g0();function KT($){let Z={DEFAULT_TOLERANCE:300,signature:null,constructEvent(V,U,K,T,w,D){try{if(!this.signature)throw Error("ERR: missing signature helper, unable to verify");this.signature.verifyHeader(V,U,K,T||Z.DEFAULT_TOLERANCE,w,D)}catch(E){if(E instanceof zT.CryptoProviderOnlySupportsAsyncError)E.message+="\nUse `await constructEventAsync(...)` instead of `constructEvent(...)`";throw E}let C=V instanceof Uint8Array?JSON.parse(new TextDecoder("utf8").decode(V)):JSON.parse(V);if(C&&C.object==="v2.core.event")throw Error("You passed an event notification to stripe.webhooks.constructEvent, which expects a webhook payload. Use stripe.parseEventNotification instead.");return C},async constructEventAsync(V,U,K,T,w,D){if(!this.signature)throw Error("ERR: missing signature helper, unable to verify");await this.signature.verifyHeaderAsync(V,U,K,T||Z.DEFAULT_TOLERANCE,w,D);let C=V instanceof Uint8Array?JSON.parse(new TextDecoder("utf8").decode(V)):JSON.parse(V);if(C&&C.object==="v2.core.event")throw Error("You passed an event notification to stripe.webhooks.constructEvent, which expects a webhook payload. Use stripe.parseEventNotification instead.");return C},generateTestHeaderString:function(V){let U=B(V),K=U.signature||U.cryptoProvider.computeHMACSignature(U.payloadString,U.secret);return U.generateHeaderString(K)},generateTestHeaderStringAsync:async function(V){let U=B(V),K=U.signature||await U.cryptoProvider.computeHMACSignatureAsync(U.payloadString,U.secret);return U.generateHeaderString(K)}},J={EXPECTED_SCHEME:"v1",verifyHeader(V,U,K,T,w,D){let{decodedHeader:C,decodedPayload:E,details:k,suspectPayloadType:I}=X(V,U,this.EXPECTED_SCHEME),R=/\s/.test(K);w=w||L();let M=w.computeHMACSignature(Y(E,k),K);return Q(E,C,k,M,T,I,R,D),!0},async verifyHeaderAsync(V,U,K,T,w,D){let{decodedHeader:C,decodedPayload:E,details:k,suspectPayloadType:I}=X(V,U,this.EXPECTED_SCHEME),R=/\s/.test(K);w=w||L();let M=await w.computeHMACSignatureAsync(Y(E,k),K);return Q(E,C,k,M,T,I,R,D)}};function Y(V,U){return`${U.timestamp}.${V}`}function X(V,U,K){if(!V)throw new s.StripeSignatureVerificationError(U,V,{message:"No webhook payload was provided."});let T=typeof V!="string"&&!(V instanceof Uint8Array),w=new TextDecoder("utf8"),D=V instanceof Uint8Array?w.decode(V):V;if(Array.isArray(U))throw Error("Unexpected: An array was passed as a header, which should not be possible for the stripe-signature header.");if(U==null||U=="")throw new s.StripeSignatureVerificationError(U,V,{message:"No stripe-signature header value was provided."});let C=U instanceof Uint8Array?w.decode(U):U,E=G(C,K);if(!E||E.timestamp===-1)throw new s.StripeSignatureVerificationError(C,D,{message:"Unable to extract timestamp and signatures from header"});if(!E.signatures.length)throw new s.StripeSignatureVerificationError(C,D,{message:"No signatures found with expected scheme"});return{decodedPayload:D,decodedHeader:C,details:E,suspectPayloadType:T}}function Q(V,U,K,T,w,D,C,E){let k=!!K.signatures.filter($.secureCompare.bind($,T)).length,I=`
3
- Learn more about webhook signing and explore webhook integration examples for various frameworks at https://docs.stripe.com/webhooks/signature`,R=C?`
2
+ var a3=Object.create;var{getPrototypeOf:o3,defineProperty:w9,getOwnPropertyNames:s3}=Object;var r3=Object.prototype.hasOwnProperty;function t3($){return this[$]}var e3,$B,ZB=($,Z,J)=>{var Q=$!=null&&typeof $==="object";if(Q){var X=Z?e3??=new WeakMap:$B??=new WeakMap,Y=X.get($);if(Y)return Y}J=$!=null?a3(o3($)):{};let G=Z||!$||!$.__esModule?w9(J,"default",{value:$,enumerable:!0}):J;for(let V of s3($))if(!r3.call(G,V))w9(G,V,{get:t3.bind($,V),enumerable:!0});if(Q)X.set($,G);return G};var K=($,Z)=>()=>(Z||$((Z={exports:{}}).exports,Z),Z.exports);var C=import.meta.require;var b0=K((u9)=>{Object.defineProperty(u9,"__esModule",{value:!0});u9.CryptoProviderOnlySupportsAsyncError=u9.CryptoProvider=void 0;class h9{computeHMACSignature($,Z){throw Error("computeHMACSignature not implemented.")}computeHMACSignatureAsync($,Z){throw Error("computeHMACSignatureAsync not implemented.")}computeSHA256Async($){throw Error("computeSHA256 not implemented.")}}u9.CryptoProvider=h9;class m9 extends Error{}u9.CryptoProviderOnlySupportsAsyncError=m9});var i9=K((p9)=>{Object.defineProperty(p9,"__esModule",{value:!0});p9.NodeCryptoProvider=void 0;var n9=C("crypto"),SB=b0();class l9 extends SB.CryptoProvider{computeHMACSignature($,Z){return n9.createHmac("sha256",Z).update($,"utf8").digest("hex")}async computeHMACSignatureAsync($,Z){return await this.computeHMACSignature($,Z)}async computeSHA256Async($){return new Uint8Array(await n9.createHash("sha256").update($).digest())}}p9.NodeCryptoProvider=l9});var j0=K((o9)=>{Object.defineProperty(o9,"__esModule",{value:!0});o9.HttpClientResponse=o9.HttpClient=void 0;class H0{getClientName(){throw Error("getClientName not implemented.")}makeRequest($,Z,J,Q,X,Y,G,V){throw Error("makeRequest not implemented.")}static makeTimeoutError(){let $=TypeError(H0.TIMEOUT_ERROR_CODE);return $.code=H0.TIMEOUT_ERROR_CODE,$}}o9.HttpClient=H0;H0.CONNECTION_CLOSED_ERROR_CODES=["ECONNRESET","EPIPE"];H0.TIMEOUT_ERROR_CODE="ETIMEDOUT";class a9{constructor($,Z){this._statusCode=$,this._headers=Z}getStatusCode(){return this._statusCode}getHeaders(){return this._headers}getRawResponse(){throw Error("getRawResponse not implemented.")}toStream($){throw Error("toStream not implemented.")}toJSON(){throw Error("toJSON not implemented.")}}o9.HttpClientResponse=a9});var XZ=K((JZ)=>{Object.defineProperty(JZ,"__esModule",{value:!0});JZ.NodeHttpClientResponse=JZ.NodeHttpClient=void 0;var r9=C("http"),t9=C("https"),A$=j0(),e9=r9.default||r9,$Z=t9.default||t9,vB=new e9.Agent({keepAlive:!0}),yB=new $Z.Agent({keepAlive:!0});class ZZ extends A$.HttpClient{constructor($){super();this._agent=$}getClientName(){return"node"}makeRequest($,Z,J,Q,X,Y,G,V){let U=G==="http",W=this._agent;if(!W)W=U?vB:yB;return new Promise((z,L)=>{let H=(U?e9:$Z).request({host:$,port:Z,path:J,method:Q,agent:W,headers:X,ciphers:"DEFAULT:!aNULL:!eNULL:!LOW:!EXPORT:!SSLv2:!MD5"});H.setTimeout(V,()=>{H.destroy(A$.HttpClient.makeTimeoutError())}),H.on("response",(T)=>{z(new N$(T))}),H.on("error",(T)=>{L(T)}),H.once("socket",(T)=>{if(T.connecting)T.once(U?"connect":"secureConnect",()=>{H.write(Y),H.end()});else H.write(Y),H.end()})})}}JZ.NodeHttpClient=ZZ;class N$ extends A$.HttpClientResponse{constructor($){super($.statusCode,$.headers||{});this._res=$}getRawResponse(){return this._res}toStream($){return this._res.once("end",()=>$()),this._res}toJSON(){return new Promise(($,Z)=>{let J="";this._res.setEncoding("utf8"),this._res.on("data",(Q)=>{J+=Q}),this._res.once("end",()=>{try{$(JSON.parse(J))}catch(Q){Z(Q)}})})}}JZ.NodeHttpClientResponse=N$});var c=K((WZ)=>{Object.defineProperty(WZ,"__esModule",{value:!0});WZ.parseHeadersForFetch=WZ.parseHttpHeaderAsNumber=WZ.parseHttpHeaderAsString=WZ.getAPIMode=WZ.jsonStringifyRequestData=WZ.concat=WZ.createApiKeyAuthenticator=WZ.detectAIAgent=WZ.AI_AGENTS=WZ.determineProcessUserAgentProperties=WZ.validateInteger=WZ.flattenAndStringify=WZ.isObject=WZ.emitWarning=WZ.pascalToCamelCase=WZ.callbackifyPromiseWithTimeout=WZ.normalizeHeader=WZ.normalizeHeaders=WZ.removeNullish=WZ.protoExtend=WZ.getOptionsFromArgs=WZ.getDataFromArgs=WZ.extractUrlParams=WZ.makeURLInterpolator=WZ.queryStringifyRequestData=WZ.isOptionsHash=void 0;var I$=["apiKey","idempotencyKey","stripeAccount","apiVersion","maxNetworkRetries","timeout","host","authenticator","stripeContext","headers","additionalHeaders","streaming"];function P$($){return $&&typeof $==="object"&&I$.some((Z)=>Object.prototype.hasOwnProperty.call($,Z))}WZ.isOptionsHash=P$;function jB($){return MB($)}WZ.queryStringifyRequestData=jB;function YZ($){return encodeURIComponent($).replace(/!/g,"%21").replace(/\*/g,"%2A").replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/'/g,"%27").replace(/%5B/g,"[").replace(/%5D/g,"]")}function fB($){if($ instanceof Date)return Math.floor($.getTime()/1000).toString();if($===null)return"";return String($)}function MB($){let Z=[];function J(Q,X){if(X===void 0)return;if(X===null||typeof X!=="object"||X instanceof Date){Z.push(YZ(Q)+"="+YZ(fB(X)));return}if(Array.isArray(X)){for(let Y=0;Y<X.length;Y++)if(X[Y]!==void 0)J(Q+"["+Y+"]",X[Y]);return}for(let Y of Object.keys(X))J(Q+"["+Y+"]",X[Y])}if(typeof $==="object"&&$!==null)for(let Q of Object.keys($))J(Q,$[Q]);return Z.join("&")}WZ.makeURLInterpolator=(()=>{let $={"\n":"\\n",'"':"\\\"","\u2028":"\\u2028","\u2029":"\\u2029"};return(Z)=>{let J=Z.replace(/["\n\r\u2028\u2029]/g,(Q)=>$[Q]);return(Q)=>{return J.replace(/\{([\s\S]+?)\}/g,(X,Y)=>{let G=Q[Y];if(_B(G))return encodeURIComponent(G);return""})}}})();function _B($){return["number","string","boolean"].includes(typeof $)}function gB($){let Z=$.match(/\{\w+\}/g);if(!Z)return[];return Z.map((J)=>J.replace(/[{}]/g,""))}WZ.extractUrlParams=gB;function hB($){if(!Array.isArray($)||!$[0]||typeof $[0]!=="object")return{};if(!P$($[0]))return $.shift();let Z=Object.keys($[0]),J=Z.filter((Q)=>I$.includes(Q));if(J.length>0&&J.length!==Z.length)S$(`Options found in arguments (${J.join(", ")}). Did you mean to pass an options object? See https://github.com/stripe/stripe-node/wiki/Passing-Options.`);return{}}WZ.getDataFromArgs=hB;function mB($){let Z={host:null,headers:{},settings:{},streaming:!1};if($.length>0){let J=$[$.length-1];if(typeof J==="string")Z.authenticator=x$($.pop());else if(P$(J)){let Q={...$.pop()},X=Object.keys(Q).filter((Y)=>!I$.includes(Y));if(X.length)S$(`Invalid options found (${X.join(", ")}); ignoring.`);if(Q.apiKey)Z.authenticator=x$(Q.apiKey);if(Q.idempotencyKey)Z.headers["Idempotency-Key"]=Q.idempotencyKey;if(Q.stripeAccount)Z.headers["Stripe-Account"]=Q.stripeAccount;if(Q.stripeContext){if(Z.headers["Stripe-Account"])throw Error("Can't specify both stripeAccount and stripeContext.");Z.headers["Stripe-Context"]=Q.stripeContext}if(Q.apiVersion)Z.headers["Stripe-Version"]=Q.apiVersion;if(Number.isInteger(Q.maxNetworkRetries))Z.settings.maxNetworkRetries=Q.maxNetworkRetries;if(Number.isInteger(Q.timeout))Z.settings.timeout=Q.timeout;if(Q.host)Z.host=Q.host;if(Q.authenticator){if(Q.apiKey)throw Error("Can't specify both apiKey and authenticator.");if(typeof Q.authenticator!=="function")throw Error("The authenticator must be a function receiving a request as the first parameter.");Z.authenticator=Q.authenticator}if(Q.headers)Object.assign(Z.headers,Q.headers);if(Q.additionalHeaders)Object.assign(Z.headers,Q.additionalHeaders);if(Q.streaming)Z.streaming=!0}}return Z}WZ.getOptionsFromArgs=mB;function uB($){let Z=this,J=Object.prototype.hasOwnProperty.call($,"constructor")?$.constructor:function(...Q){Z.apply(this,Q)};return Object.assign(J,Z),J.prototype=Object.create(Z.prototype),Object.assign(J.prototype,$),J}WZ.protoExtend=uB;function cB($){if(typeof $!=="object")throw Error("Argument must be an object");return Object.keys($).reduce((Z,J)=>{if($[J]!=null)Z[J]=$[J];return Z},{})}WZ.removeNullish=cB;function nB($){if(!($&&typeof $==="object"))return $;return Object.keys($).reduce((Z,J)=>{return Z[GZ(J)]=$[J],Z},{})}WZ.normalizeHeaders=nB;function GZ($){return $.split("-").map((Z)=>Z.charAt(0).toUpperCase()+Z.substr(1).toLowerCase()).join("-")}WZ.normalizeHeader=GZ;function lB($,Z){if(Z)return $.then((J)=>{setTimeout(()=>{Z(null,J)},0)},(J)=>{setTimeout(()=>{Z(J,null)},0)});return $}WZ.callbackifyPromiseWithTimeout=lB;function pB($){if($==="OAuth")return"oauth";else return $[0].toLowerCase()+$.substring(1)}WZ.pascalToCamelCase=pB;function S$($){if(typeof process.emitWarning!=="function")return console.warn(`Stripe: ${$}`);return process.emitWarning($,"Stripe")}WZ.emitWarning=S$;function VZ($){let Z=typeof $;return(Z==="function"||Z==="object")&&!!$}WZ.isObject=VZ;function dB($){let Z={},J=(Q,X)=>{Object.entries(Q).forEach(([Y,G])=>{let V=X?`${X}[${Y}]`:Y;if(VZ(G))if(!(G instanceof Uint8Array)&&!Object.prototype.hasOwnProperty.call(G,"data"))return J(G,V);else Z[V]=G;else Z[V]=String(G)})};return J($,null),Z}WZ.flattenAndStringify=dB;function iB($,Z,J){if(!Number.isInteger(Z))if(J!==void 0)return J;else throw Error(`${$} must be an integer`);return Z}WZ.validateInteger=iB;function aB(){return typeof process>"u"?{}:{lang_version:process.version}}WZ.determineProcessUserAgentProperties=aB;WZ.AI_AGENTS=[["ANTIGRAVITY_CLI_ALIAS","antigravity"],["CLAUDECODE","claude_code"],["CLINE_ACTIVE","cline"],["CODEX_SANDBOX","codex_cli"],["CODEX_THREAD_ID","codex_cli"],["CODEX_SANDBOX_NETWORK_DISABLED","codex_cli"],["CODEX_CI","codex_cli"],["CURSOR_AGENT","cursor"],["GEMINI_CLI","gemini_cli"],["OPENCLAW_SHELL","openclaw"],["OPENCODE","open_code"]];function oB($){for(let[Z,J]of WZ.AI_AGENTS)if($[Z])return J;return""}WZ.detectAIAgent=oB;function x$($){let Z=(J)=>{return J.headers.Authorization="Bearer "+$,Promise.resolve()};return Z._apiKey=$,Z}WZ.createApiKeyAuthenticator=x$;function sB($){let Z=$.reduce((X,Y)=>X+Y.length,0),J=new Uint8Array(Z),Q=0;return $.forEach((X)=>{J.set(X,Q),Q+=X.length}),J}WZ.concat=sB;function rB($,Z){if(this[$]instanceof Date)return Math.floor(this[$].getTime()/1000).toString();return Z}function tB($){return JSON.stringify($,rB)}WZ.jsonStringifyRequestData=tB;function eB($){if(!$)return"v1";return $.startsWith("/v2")?"v2":"v1"}WZ.getAPIMode=eB;function BZ($){if(Array.isArray($))return $.join(", ");return String($)}WZ.parseHttpHeaderAsString=BZ;function $W($){let Z=Array.isArray($)?$[0]:$;return Number(Z)}WZ.parseHttpHeaderAsNumber=$W;function ZW($){return Object.entries($).map(([Z,J])=>{return[Z,BZ(J)]})}WZ.parseHeadersForFetch=ZW});var HZ=K((LZ)=>{Object.defineProperty(LZ,"__esModule",{value:!0});LZ.FetchHttpClientResponse=LZ.FetchHttpClient=void 0;var xW=c(),f0=j0();class E8 extends f0.HttpClient{constructor($){super();if(!$){if(!globalThis.fetch)throw Error("fetch() function not provided and is not defined in the global scope. You must provide a fetch implementation.");$=globalThis.fetch}if(globalThis.AbortController)this._fetchFn=E8.makeFetchWithAbortTimeout($);else this._fetchFn=E8.makeFetchWithRaceTimeout($)}static makeFetchWithRaceTimeout($){return(Z,J,Q)=>{let X,Y=new Promise((V,U)=>{X=setTimeout(()=>{X=null,U(f0.HttpClient.makeTimeoutError())},Q)}),G=$(Z,J);return Promise.race([G,Y]).finally(()=>{if(X)clearTimeout(X)})}}static makeFetchWithAbortTimeout($){return async(Z,J,Q)=>{let X=new AbortController,Y=setTimeout(()=>{Y=null,X.abort(f0.HttpClient.makeTimeoutError())},Q);try{return await $(Z,{...J,signal:X.signal})}catch(G){if(G.name==="AbortError")throw f0.HttpClient.makeTimeoutError();else throw G}finally{if(Y)clearTimeout(Y)}}}getClientName(){return"fetch"}async makeRequest($,Z,J,Q,X,Y,G,V){let W=new URL(J,`${G==="http"?"http":"https"}://${$}`);W.port=Z;let B=Q=="POST"||Q=="PUT"||Q=="PATCH",z=Y||(B?"":void 0),L=await this._fetchFn(W.toString(),{method:Q,headers:(0,xW.parseHeadersForFetch)(X),body:z},V);return new F8(L)}}LZ.FetchHttpClient=E8;class F8 extends f0.HttpClientResponse{constructor($){super($.status,F8._transformHeadersToObject($.headers));this._res=$}getRawResponse(){return this._res}toStream($){return $(),this._res.body}toJSON(){return this._res.json()}static _transformHeadersToObject($){let Z={};for(let J of $){if(!Array.isArray(J)||J.length!=2)throw Error("Response objects produced by the fetch function given to FetchHttpClient do not have an iterable headers map. Response#headers should be an iterable object.");Z[J[0]]=J[1]}return Z}}LZ.FetchHttpClientResponse=F8});var qZ=K((DZ)=>{Object.defineProperty(DZ,"__esModule",{value:!0});DZ.SubtleCryptoProvider=void 0;var wZ=b0();class TZ extends wZ.CryptoProvider{constructor($){super();this.subtleCrypto=$||crypto.subtle}computeHMACSignature($,Z){throw new wZ.CryptoProviderOnlySupportsAsyncError("SubtleCryptoProvider cannot be used in a synchronous context.")}async computeHMACSignatureAsync($,Z){let J=new TextEncoder,Q=await this.subtleCrypto.importKey("raw",J.encode(Z),{name:"HMAC",hash:{name:"SHA-256"}},!1,["sign"]),X=await this.subtleCrypto.sign("hmac",Q,J.encode($)),Y=new Uint8Array(X),G=Array(Y.length);for(let V=0;V<Y.length;V++)G[V]=R$[Y[V]];return G.join("")}async computeSHA256Async($){return new Uint8Array(await this.subtleCrypto.digest("SHA-256",$))}}DZ.SubtleCryptoProvider=TZ;var R$=Array(256);for(let $=0;$<R$.length;$++)R$[$]=$.toString(16).padStart(2,"0")});var kZ=K((FZ)=>{Object.defineProperty(FZ,"__esModule",{value:!0});FZ.PlatformFunctions=void 0;var PW=HZ(),SW=qZ();class EZ{constructor(){this._fetchFn=null,this._agent=null}getPlatformInfo(){return null}uuid4(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,($)=>{let Z=Math.random()*16|0;return($==="x"?Z:Z&3|8).toString(16)})}secureCompare($,Z){if($.length!==Z.length)return!1;let J=$.length,Q=0;for(let X=0;X<J;++X)Q|=$.charCodeAt(X)^Z.charCodeAt(X);return Q===0}createEmitter(){throw Error("createEmitter not implemented.")}tryBufferData($){throw Error("tryBufferData not implemented.")}createNodeHttpClient($){throw Error("createNodeHttpClient not implemented.")}createFetchHttpClient($){return new PW.FetchHttpClient($)}createDefaultHttpClient(){throw Error("createDefaultHttpClient not implemented.")}createNodeCryptoProvider(){throw Error("createNodeCryptoProvider not implemented.")}createSubtleCryptoProvider($){return new SW.SubtleCryptoProvider($)}createDefaultCryptoProvider(){throw Error("createDefaultCryptoProvider not implemented.")}}FZ.PlatformFunctions=EZ});var M0=K((xZ)=>{Object.defineProperty(xZ,"__esModule",{value:!0});xZ.TemporarySessionExpiredError=xZ.RateLimitError=xZ.StripeUnsupportedResponseTypeError=xZ.StripeUnsupportedGrantTypeError=xZ.StripeInvalidScopeError=xZ.StripeOAuthInvalidRequestError=xZ.StripeInvalidClientError=xZ.StripeInvalidGrantError=xZ.StripeOAuthError=xZ.StripeIdempotencyError=xZ.StripeSignatureVerificationError=xZ.StripeConnectionError=xZ.StripeRateLimitError=xZ.StripePermissionError=xZ.StripeAuthenticationError=xZ.StripeAPIError=xZ.StripeInvalidRequestError=xZ.StripeCardError=xZ.StripeError=xZ.generateV2Error=xZ.generateOAuthError=xZ.generateV1Error=void 0;var RW=($)=>{let Z=$.statusCode;if(Z===429||Z===400&&$.code==="rate_limit")return new f$($);if(Z===400||Z===404){if($.type==="idempotency_error")return new k8($);return new C8($)}if(Z===401)return new b$($);if(Z===402)return new v$($);if(Z===403)return new j$($);return new y$($)};xZ.generateV1Error=RW;var vW=($)=>{switch($.type){case"invalid_grant":return new M$($);case"invalid_client":return new _$($);case"invalid_request":return new g$($);case"invalid_scope":return new h$($);case"unsupported_grant_type":return new m$($);case"unsupported_response_type":return new u$($);default:return new d($)}};xZ.generateOAuthError=vW;var yW=($)=>{switch($.type){case"idempotency_error":return new k8($);case"rate_limit":return new c$($);case"temporary_session_expired":return new n$($)}switch($.code){case"invalid_fields":return new C8($)}return xZ.generateV1Error($)};xZ.generateV2Error=yW;class v extends Error{constructor($={},Z=null){super($.message);this.type=Z||this.constructor.name,this.raw=$,this.rawType=$.type,this.code=$.code,this.doc_url=$.doc_url,this.param=$.param,this.detail=$.detail,this.headers=$.headers,this.requestId=$.requestId,this.statusCode=$.statusCode,this.message=$.message??"",this.userMessage=$.user_message,this.charge=$.charge,this.decline_code=$.decline_code,this.payment_intent=$.payment_intent,this.payment_method=$.payment_method,this.payment_method_type=$.payment_method_type,this.setup_intent=$.setup_intent,this.source=$.source}}xZ.StripeError=v;v.generate=xZ.generateV1Error;class v$ extends v{constructor($={}){super($,"StripeCardError")}}xZ.StripeCardError=v$;class C8 extends v{constructor($={}){super($,"StripeInvalidRequestError")}}xZ.StripeInvalidRequestError=C8;class y$ extends v{constructor($={}){super($,"StripeAPIError")}}xZ.StripeAPIError=y$;class b$ extends v{constructor($={}){super($,"StripeAuthenticationError")}}xZ.StripeAuthenticationError=b$;class j$ extends v{constructor($={}){super($,"StripePermissionError")}}xZ.StripePermissionError=j$;class f$ extends v{constructor($={}){super($,"StripeRateLimitError")}}xZ.StripeRateLimitError=f$;class AZ extends v{constructor($={}){super($,"StripeConnectionError")}}xZ.StripeConnectionError=AZ;class NZ extends v{constructor($,Z,J={}){super(J,"StripeSignatureVerificationError");this.header=$,this.payload=Z}}xZ.StripeSignatureVerificationError=NZ;class k8 extends v{constructor($={}){super($,"StripeIdempotencyError")}}xZ.StripeIdempotencyError=k8;class d extends v{constructor($={},Z="StripeOAuthError"){super($,Z)}}xZ.StripeOAuthError=d;class M$ extends d{constructor($={}){super($,"StripeInvalidGrantError")}}xZ.StripeInvalidGrantError=M$;class _$ extends d{constructor($={}){super($,"StripeInvalidClientError")}}xZ.StripeInvalidClientError=_$;class g$ extends d{constructor($={}){super($,"StripeOAuthInvalidRequestError")}}xZ.StripeOAuthInvalidRequestError=g$;class h$ extends d{constructor($={}){super($,"StripeInvalidScopeError")}}xZ.StripeInvalidScopeError=h$;class m$ extends d{constructor($={}){super($,"StripeUnsupportedGrantTypeError")}}xZ.StripeUnsupportedGrantTypeError=m$;class u$ extends d{constructor($={}){super($,"StripeUnsupportedResponseTypeError")}}xZ.StripeUnsupportedResponseTypeError=u$;class c$ extends v{constructor($={}){super($,"RateLimitError")}}xZ.RateLimitError=c$;class n$ extends v{constructor($={}){super($,"TemporarySessionExpiredError")}}xZ.TemporarySessionExpiredError=n$});var fZ=K((bZ)=>{Object.defineProperty(bZ,"__esModule",{value:!0});bZ.NodePlatformFunctions=void 0;var A8=C("crypto"),PZ=C("events"),eW=i9(),SZ=XZ(),$U=kZ(),ZU=M0(),JU=c(),RZ=C("os");class vZ extends ZU.StripeError{}class yZ extends $U.PlatformFunctions{uuid4(){if(A8.randomUUID)return A8.randomUUID();return super.uuid4()}getPlatformInfo(){return`${process.platform} ${(0,RZ.release)()} ${(0,RZ.arch)()}`}secureCompare($,Z){if(!$||!Z)throw Error("secureCompare must receive two arguments");if($.length!==Z.length)return!1;if(A8.timingSafeEqual){let J=new TextEncoder,Q=J.encode($),X=J.encode(Z);return A8.timingSafeEqual(Q,X)}return super.secureCompare($,Z)}createEmitter(){return new PZ.EventEmitter}tryBufferData($){if(!($.file.data instanceof PZ.EventEmitter))return Promise.resolve($);let Z=[];return new Promise((J,Q)=>{$.file.data.on("data",(X)=>{Z.push(X)}).once("end",()=>{let X=Object.assign({},$);X.file.data=(0,JU.concat)(Z),J(X)}).on("error",(X)=>{Q(new vZ({message:"An error occurred while attempting to process the file for upload.",detail:X}))})})}createNodeHttpClient($){return new SZ.NodeHttpClient($)}createDefaultHttpClient(){return new SZ.NodeHttpClient}createNodeCryptoProvider(){return new eW.NodeCryptoProvider}createDefaultCryptoProvider(){return this.createNodeCryptoProvider()}}bZ.NodePlatformFunctions=yZ});var hZ=K((_Z)=>{Object.defineProperty(_Z,"__esModule",{value:!0});_Z.RequestSender=void 0;var w0=M0(),MZ=j0(),j=c(),QU=60;class _0{constructor($,Z){this._stripe=$,this._maxBufferedRequestMetric=Z}_normalizeStripeContext($,Z){if($)return $.toString()||null;return Z?.toString()||null}_addHeadersDirectlyToObject($,Z){$.requestId=Z["request-id"],$.stripeAccount=$.stripeAccount||Z["stripe-account"],$.apiVersion=$.apiVersion||Z["stripe-version"],$.idempotencyKey=$.idempotencyKey||Z["idempotency-key"]}_makeResponseEvent($,Z,J){let Q=Date.now(),X=Q-$.request_start_time;return(0,j.removeNullish)({api_version:J["stripe-version"],account:J["stripe-account"],idempotency_key:J["idempotency-key"],method:$.method,path:$.path,status:Z,request_id:this._getRequestId(J),elapsed:X,request_start_time:$.request_start_time,request_end_time:Q})}_getRequestId($){return $["request-id"]}_streamingResponseHandler($,Z,J){return(Q)=>{let X=Q.getHeaders(),Y=()=>{let V=this._makeResponseEvent($,Q.getStatusCode(),X);this._stripe._emitter.emit("response",V),this._recordRequestMetrics(this._getRequestId(X),V.elapsed,Z)},G=Q.toStream(Y);return this._addHeadersDirectlyToObject(G,X),J(null,G)}}_jsonResponseHandler($,Z,J,Q){return(X)=>{let Y=X.getHeaders(),G=this._getRequestId(Y),V=X.getStatusCode(),U=this._makeResponseEvent($,V,Y);this._stripe._emitter.emit("response",U),X.toJSON().then((W)=>{if(W.error){let B=typeof W.error==="string";if(B)W.error={type:W.error,message:W.error_description};W.error.headers=Y,W.error.statusCode=V,W.error.requestId=G;let z;if(B)z=(0,w0.generateOAuthError)(W.error);else if(Z==="v2")z=(0,w0.generateV2Error)(W.error);else z=(0,w0.generateV1Error)(W.error);throw z}return W},(W)=>{throw new w0.StripeAPIError({message:"Invalid JSON received from the Stripe API",exception:W,requestId:Y["request-id"]})}).then((W)=>{this._recordRequestMetrics(G,U.elapsed,J);let B=X.getRawResponse();this._addHeadersDirectlyToObject(B,Y),Object.defineProperty(W,"lastResponse",{enumerable:!1,writable:!1,value:B}),Q(null,W)},(W)=>Q(W,null))}}static _generateConnectionErrorMessage($){return`An error occurred with our connection to Stripe.${$>0?` Request was retried ${$} times.`:""}`}static _shouldRetry($,Z,J,Q){if(Q&&Z===0&&MZ.HttpClient.CONNECTION_CLOSED_ERROR_CODES.includes(Q.code))return!0;if(Z>=J)return!1;if(!$)return!0;if($.getHeaders()["stripe-should-retry"]==="false")return!1;if($.getHeaders()["stripe-should-retry"]==="true")return!0;if($.getStatusCode()===409)return!0;if($.getStatusCode()>=500)return!0;return!1}_getSleepTimeInMS($,Z=null){let J=this._stripe.getInitialNetworkRetryDelay(),Q=this._stripe.getMaxNetworkRetryDelay(),X=Math.min(J*Math.pow(2,$-1),Q);if(X*=0.5*(1+Math.random()),X=Math.max(J,X),Number.isInteger(Z)&&Z<=QU)X=Math.max(X,Z);return X*1000}_getMaxNetworkRetries($={}){return $.maxNetworkRetries!==void 0&&Number.isInteger($.maxNetworkRetries)?$.maxNetworkRetries:this._stripe.getMaxNetworkRetries()}_defaultIdempotencyKey($,Z,J){let Q=this._getMaxNetworkRetries(Z),X=()=>`stripe-node-retry-${this._stripe._platformFunctions.uuid4()}`;if(J==="v2"){if($==="POST"||$==="DELETE")return X()}else if(J==="v1"){if($==="POST"&&Q>0)return X()}return null}_makeHeaders({contentType:$,contentLength:Z,apiVersion:J,clientUserAgent:Q,method:X,userSuppliedHeaders:Y,userSuppliedSettings:G,stripeAccount:V,stripeContext:U,apiMode:W}){let B={Accept:"application/json","Content-Type":$,"User-Agent":this._getUserAgentString(W),"X-Stripe-Client-User-Agent":Q,"X-Stripe-Client-Telemetry":this._getTelemetryHeader(),"Stripe-Version":J,"Stripe-Account":V,"Stripe-Context":U,"Idempotency-Key":this._defaultIdempotencyKey(X,G,W)},z=X=="POST"||X=="PUT"||X=="PATCH";if(z||Z){if(!z)(0,j.emitWarning)(`${X} method had non-zero contentLength but no payload is expected for this verb`);B["Content-Length"]=Z}return Object.assign((0,j.removeNullish)(B),(0,j.normalizeHeaders)(Y))}_getUserAgentString($){let Z=this._stripe.getConstant("PACKAGE_VERSION"),J=this._stripe._appInfo?this._stripe.getAppInfoAsString():"",Q=this._stripe.getConstant("AI_AGENT"),X=`Stripe/${$} NodeBindings/${Z}`;if(J)X+=` ${J}`;if(Q)X+=` AIAgent/${Q}`;return X}_getTelemetryHeader(){if(this._stripe.getTelemetryEnabled()&&this._stripe._prevRequestMetrics.length>0){let $=this._stripe._prevRequestMetrics.shift();return JSON.stringify({last_request_metrics:$})}}_recordRequestMetrics($,Z,J){if(this._stripe.getTelemetryEnabled()&&$)if(this._stripe._prevRequestMetrics.length>this._maxBufferedRequestMetric)(0,j.emitWarning)("Request metrics buffer is full, dropping telemetry message.");else{let Q={request_id:$,request_duration_ms:Z};if(J&&J.length>0)Q.usage=J;this._stripe._prevRequestMetrics.push(Q)}}_rawRequest($,Z,J,Q,X){return new Promise((G,V)=>{let U;try{let H=$.toUpperCase();if(H!=="POST"&&J&&Object.keys(J).length!==0)throw Error("rawRequest only supports params on POST requests. Please pass null and add your parameters to path.");let T=[].slice.call([J,Q]),D=(0,j.getDataFromArgs)(T),q=H==="POST"?Object.assign({},D):null,O=(0,j.getOptionsFromArgs)(T),k=O.headers,N=O.authenticator;U={requestMethod:H,requestPath:Z,bodyData:q,queryData:{},authenticator:N,headers:k,host:O.host,streaming:!!O.streaming,settings:{},usage:X||["raw_request"]}}catch(H){V(H);return}function W(H,T){if(H)V(H);else G(T)}let{headers:B,settings:z}=U,L=U.authenticator;this._request(U.requestMethod,U.host,Z,U.bodyData,L,{headers:B,settings:z,streaming:U.streaming},U.usage,W)})}_getContentLength($){return typeof $==="string"?new TextEncoder().encode($).length:$.length}_request($,Z,J,Q,X,Y,G=[],V,U=null){let W;X=X??this._stripe._authenticator??null;let B=(0,j.getAPIMode)(J),z=(T,D,q,O,k)=>{return setTimeout(T,this._getSleepTimeInMS(O,k),D,q,O+1)},L=(T,D,q)=>{let O=Y.settings&&Y.settings.timeout&&Number.isInteger(Y.settings.timeout)&&Y.settings.timeout>=0?Y.settings.timeout:this._stripe.getApiField("timeout"),k={host:Z||this._stripe.getApiField("host"),port:this._stripe.getApiField("port"),path:J,method:$,headers:Object.assign({},D),body:W,protocol:this._stripe.getApiField("protocol")};X(k).then(()=>{let N=this._stripe.getApiField("httpClient").makeRequest(k.host,k.port,k.path,k.method,k.headers,k.body,k.protocol,O),R=Date.now(),M=(0,j.removeNullish)({api_version:T,account:(0,j.parseHttpHeaderAsString)(D["Stripe-Account"]),idempotency_key:(0,j.parseHttpHeaderAsString)(D["Idempotency-Key"]),method:$,path:J,request_start_time:R}),_=q||0,P0=this._getMaxNetworkRetries(Y.settings||{});this._stripe._emitter.emit("request",M),N.then((y)=>{if(_0._shouldRetry(y,_,P0))return z(L,T,D,_,(0,j.parseHttpHeaderAsNumber)(y.getHeaders()["retry-after"]));else if(Y.streaming&&y.getStatusCode()<400)return this._streamingResponseHandler(M,G,V)(y);else return this._jsonResponseHandler(M,B,G,V)(y)}).catch((y)=>{if(_0._shouldRetry(null,_,P0,y))return z(L,T,D,_,null);else{let i3=y.code&&y.code===MZ.HttpClient.TIMEOUT_ERROR_CODE;return V(new w0.StripeConnectionError({message:i3?`Request aborted due to timeout being reached (${O}ms)`:_0._generateConnectionErrorMessage(_),detail:y}))}})}).catch((N)=>{throw new w0.StripeError({message:"Unable to authenticate the request",exception:N})})},H=(T,D)=>{if(T)return V(T);W=D,this._stripe.getClientUserAgent((q)=>{let O=this._stripe.getApiField("version"),k=this._makeHeaders({contentType:B=="v2"?"application/json":"application/x-www-form-urlencoded",contentLength:this._getContentLength(D),apiVersion:O,clientUserAgent:q,method:$,userSuppliedHeaders:Y.headers??null,userSuppliedSettings:Y.settings??{},stripeAccount:Y.stripeAccount??this._stripe.getApiField("stripeAccount"),stripeContext:this._normalizeStripeContext(Y.stripeContext,this._stripe.getApiField("stripeContext")),apiMode:B});L(O,k,0)})};if(U)U($,Q,Y.headers,H);else{let T;if(B=="v2")T=Q?(0,j.jsonStringifyRequestData)(Q):"";else T=(0,j.queryStringifyRequestData)(Q||{});H(null,T)}}}_Z.RequestSender=_0});var dZ=K((lZ)=>{Object.defineProperty(lZ,"__esModule",{value:!0});lZ.makeAutoPaginationMethods=void 0;var N8=c();class d${constructor($,Z,J,Q){this.index=0,this.pagePromise=$,this.promiseCache={currentPromise:null},this.requestArgs=Z,this.spec=J,this.stripeResource=Q}async iterate($){if(!($&&$.data&&typeof $.data.length==="number"))throw Error("Unexpected: Stripe API response does not have a well-formed `data` array.");let Z=nZ(this.requestArgs);if(this.index<$.data.length){let J=Z?$.data.length-1-this.index:this.index,Q=$.data[J];return this.index+=1,{value:Q,done:!1}}else if($.has_more){this.index=0,this.pagePromise=this.getNextPage($);let J=await this.pagePromise;return this.iterate(J)}return{done:!0,value:void 0}}getNextPage($){throw Error("Unimplemented")}async _next(){return this.iterate(await this.pagePromise)}next(){if(this.promiseCache.currentPromise)return this.promiseCache.currentPromise;let $=(async()=>{let Z=await this._next();return this.promiseCache.currentPromise=null,Z})();return this.promiseCache.currentPromise=$,$}}class mZ extends d${getNextPage($){let Z=nZ(this.requestArgs),J=BU($,Z);return this.stripeResource._makeRequest(this.requestArgs,this.spec,{[Z?"ending_before":"starting_after"]:J})}}class uZ extends d${getNextPage($){if(!$.next_page)throw Error("Unexpected: Stripe API response does not have a well-formed `next_page` field, but `has_more` was true.");return this.stripeResource._makeRequest(this.requestArgs,this.spec,{page:$.next_page})}}class cZ{constructor($,Z,J,Q){this.firstPagePromise=$,this.currentPageIterator=null,this.nextPageUrl=null,this.requestArgs=Z,this.spec=J,this.stripeResource=Q}async initFirstPage(){if(this.firstPagePromise){let $=await this.firstPagePromise;this.firstPagePromise=null,this.currentPageIterator=$.data[Symbol.iterator](),this.nextPageUrl=$.next_page_url||null}}async turnPage(){if(!this.nextPageUrl)return null;this.spec.fullPath=this.nextPageUrl;let $=await this.stripeResource._makeRequest([],this.spec,{});return this.nextPageUrl=$.next_page_url||null,this.currentPageIterator=$.data[Symbol.iterator](),this.currentPageIterator}async next(){if(await this.initFirstPage(),this.currentPageIterator){let J=this.currentPageIterator.next();if(!J.done)return{done:!1,value:J.value}}let $=await this.turnPage();if(!$)return{done:!0,value:void 0};let Z=$.next();if(!Z.done)return{done:!1,value:Z.value};return{done:!0,value:void 0}}}var XU=($,Z,J,Q)=>{let X=(0,N8.getAPIMode)(J.fullPath||J.path);if(X!=="v2"&&J.methodType==="search")return p$(new uZ(Q,Z,J,$));if(X!=="v2"&&J.methodType==="list")return p$(new mZ(Q,Z,J,$));if(X==="v2"&&J.methodType==="list")return p$(new cZ(Q,Z,J,$));return null};lZ.makeAutoPaginationMethods=XU;var p$=($)=>{let Z=WU((...X)=>$.next(...X)),J=UU(Z),Q={autoPagingEach:Z,autoPagingToArray:J,next:()=>$.next(),return:()=>{return{}},[YU()]:()=>{return Q}};return Q};function YU(){if(typeof Symbol<"u"&&Symbol.asyncIterator)return Symbol.asyncIterator;return"@@asyncIterator"}function GU($){if($.length<2)return null;let Z=$[1];if(typeof Z!=="function")throw Error(`The second argument to autoPagingEach, if present, must be a callback function; received ${typeof Z}`);return Z}function VU($){if($.length===0)return;let Z=$[0];if(typeof Z!=="function")throw Error(`The first argument to autoPagingEach, if present, must be a callback function; received ${typeof Z}`);if(Z.length===2)return Z;if(Z.length>2)throw Error(`The \`onItem\` callback function passed to autoPagingEach must accept at most two arguments; got ${Z}`);return function(Q,X){let Y=Z(Q);X(Y)}}function BU($,Z){let J=Z?0:$.data.length-1,Q=$.data[J],X=Q&&Q.id;if(!X)throw Error("Unexpected: No `id` found on the last item while auto-paging a list.");return X}function WU($){return function(){let J=[].slice.call(arguments),Q=VU(J),X=GU(J);if(J.length>2)throw Error(`autoPagingEach takes up to two arguments; received ${J}`);let Y=zU($,Q);return(0,N8.callbackifyPromiseWithTimeout)(Y,X)}}function UU($){return function(J,Q){let X=J&&J.limit;if(!X)throw Error("You must pass a `limit` option to autoPagingToArray, e.g., `autoPagingToArray({limit: 1000});`.");if(X>1e4)throw Error("You cannot specify a limit of more than 10,000 items to fetch in `autoPagingToArray`; use `autoPagingEach` to iterate through longer lists.");let Y=new Promise((G,V)=>{let U=[];$((W)=>{if(U.push(W),U.length>=X)return!1}).then(()=>{G(U)}).catch(V)});return(0,N8.callbackifyPromiseWithTimeout)(Y,Q)}}function zU($,Z){return new Promise((J,Q)=>{function X(Y){if(Y.done){J();return}let G=Y.value;return new Promise((V)=>{Z(G,V)}).then((V)=>{if(V===!1)return X({done:!0,value:void 0});else return $().then(X)})}$().then(X).catch(Q)})}function nZ($){let Z=[].slice.call($);return!!(0,N8.getDataFromArgs)(Z).ending_before}});var sZ=K((aZ)=>{Object.defineProperty(aZ,"__esModule",{value:!0});aZ.stripeMethod=void 0;var iZ=c(),LU=dZ();function KU($){if($.path!==void 0&&$.fullPath!==void 0)throw Error(`Method spec specified both a 'path' (${$.path}) and a 'fullPath' (${$.fullPath}).`);return function(...Z){let J=typeof Z[Z.length-1]=="function"&&Z.pop();$.urlParams=(0,iZ.extractUrlParams)($.fullPath||this.createResourcePathWithSymbols($.path||""));let Q=(0,iZ.callbackifyPromiseWithTimeout)(this._makeRequest(Z,$,{}),J);return Object.assign(Q,(0,LU.makeAutoPaginationMethods)(this,Z,$,Q)),Q}}aZ.stripeMethod=KU});var I8=K((tZ)=>{Object.defineProperty(tZ,"__esModule",{value:!0});tZ.Decimal=tZ.isDecimal=tZ.DEFAULT_DIV_PRECISION=void 0;var HU={"ubb-usage-count":{mode:"significant-figures",value:15},"v1-api":{mode:"decimal-places",value:12}};tZ.DEFAULT_DIV_PRECISION=34;var rZ=30,x8=1e6;class P{constructor($,Z){let[J,Q]=P.normalize($,Z);this._coefficient=J,this._exponent=Q,Object.freeze(this)}static normalize($,Z){if($===0n)return[0n,0];let J=$,Q=Z;while(J!==0n&&J%10n===0n)J/=10n,Q+=1;return[J,Q]}static roundDivision($,Z,J,Q){if(Z===0n)return $;if(Q==="round-down")return $;let X=Z>0n===J>0n?1n:-1n;if(Q==="round-up")return $+X;if(Q==="ceil")return X===1n?$+1n:$;if(Q==="floor")return X===-1n?$-1n:$;let Y=Z<0n?-Z:Z,G=J<0n?-J:J,V=Y*2n,U;if(V===G)U=0;else if(V<G)U=-1;else U=1;if(U<0)return $;if(U>0)return $+X;if(Q==="half-up")return $+X;if(Q==="half-down")return $;if($%2n===0n)return $;else return $+X}add($){let Z=$;if(this._exponent===Z._exponent)return new P(this._coefficient+Z._coefficient,this._exponent);if(this._exponent<Z._exponent){let J=10n**BigInt(Z._exponent-this._exponent);return new P(this._coefficient+Z._coefficient*J,this._exponent)}else{let J=10n**BigInt(this._exponent-Z._exponent);return new P(this._coefficient*J+Z._coefficient,Z._exponent)}}sub($){let Z=$;if(this._exponent===Z._exponent)return new P(this._coefficient-Z._coefficient,this._exponent);if(this._exponent<Z._exponent){let J=10n**BigInt(Z._exponent-this._exponent);return new P(this._coefficient-Z._coefficient*J,this._exponent)}else{let J=10n**BigInt(this._exponent-Z._exponent);return new P(this._coefficient*J-Z._coefficient,Z._exponent)}}mul($){let Z=$;return new P(this._coefficient*Z._coefficient,this._exponent+Z._exponent)}div($,Z,J){if(Z<0||!Number.isInteger(Z))throw Error("precision must be a non-negative integer");let Q=$;if(Q._coefficient===0n)throw Error("Division by zero");let X=this._exponent-Q._exponent+Z,Y,G,V;if(X>=0){let W=this._coefficient*10n**BigInt(X);Y=W/Q._coefficient,G=W%Q._coefficient,V=Q._coefficient}else{let W=Q._coefficient*10n**BigInt(-X);Y=this._coefficient/W,G=this._coefficient%W,V=W}let U=P.roundDivision(Y,G,V,J);return new P(U,-Z)}cmp($){let Z=$;if(this._exponent===Z._exponent){if(this._coefficient<Z._coefficient)return-1;if(this._coefficient>Z._coefficient)return 1;return 0}if(this._exponent<Z._exponent){let J=10n**BigInt(Z._exponent-this._exponent),Q=Z._coefficient*J;if(this._coefficient<Q)return-1;if(this._coefficient>Q)return 1;return 0}else{let J=10n**BigInt(this._exponent-Z._exponent),Q=this._coefficient*J;if(Q<Z._coefficient)return-1;if(Q>Z._coefficient)return 1;return 0}}eq($){return this.cmp($)===0}lt($){return this.cmp($)===-1}lte($){return this.cmp($)<=0}gt($){return this.cmp($)===1}gte($){return this.cmp($)>=0}isZero(){return this._coefficient===0n}isNegative(){return this._coefficient<0n}isPositive(){return this._coefficient>0n}neg(){return new P(-this._coefficient,this._exponent)}abs(){if(this._coefficient<0n)return new P(-this._coefficient,this._exponent);return this}round($,Z){let J=typeof Z==="string"?HU[Z]:Z;if(J===void 0)throw Error(`Unknown rounding preset: "${Z}"`);if(J.value<0||!Number.isInteger(J.value))throw Error("DecimalRoundingOptions.value must be a non-negative integer");if(J.mode==="decimal-places"){let B=this.toFixed(J.value,$);return tZ.Decimal.from(B)}if(this._coefficient===0n)return this;let X=(this._coefficient<0n?(-this._coefficient).toString():this._coefficient.toString()).length;if(J.value===0)return tZ.Decimal.zero;if(X<=J.value)return this;let Y=X-J.value,G=10n**BigInt(Y),V=this._coefficient/G,U=this._coefficient%G,W=P.roundDivision(V,U,G,$);return new P(W,this._exponent+Y)}toString(){if(this._coefficient===0n)return"0";let $=this._coefficient.toString(),Z=$.startsWith("-"),J=Z?$.slice(1):$;if(this._exponent<0){let X=-this._exponent;if((X>=J.length?X-J.length:0)>rZ){if(J.length===1)return`${$}E${String(this._exponent)}`;let G=J[0]??"",V=J.slice(1),U=this._exponent+J.length-1;return`${Z?"-":""}${G}.${V}E${String(U)}`}if(X>=J.length){let G="0".repeat(X-J.length);return`${Z?"-":""}0.${G}${J}`}else{let G=J.slice(0,J.length-X),V=J.slice(J.length-X);return`${Z?"-":""}${G}.${V}`}}if(J.length+this._exponent<=rZ){if(this._exponent===0)return $;let X="0".repeat(this._exponent);return`${Z?"-":""}${J}${X}`}else{if(J.length===1)return`${$}E+${String(this._exponent)}`;let X=J[0]??"",Y=J.slice(1),G=this._exponent+J.length-1;return`${Z?"-":""}${X}.${Y}E+${String(G)}`}}toJSON(){return this.toString()}toNumber(){return Number(this.toString())}toFixed($,Z){if($<0||!Number.isInteger($))throw Error("decimalPlaces must be a non-negative integer");let J=(X)=>{let Y=X.toString(),G=Y.startsWith("-"),V=G?Y.slice(1):Y;if($===0)return Y;if($>=V.length){let U="0".repeat($-V.length);return`${G?"-":""}0.${U}${V}`}else{let U=V.slice(0,V.length-$),W=V.slice(V.length-$);return`${G?"-":""}${U}.${W}`}},Q=-$;if(this._exponent===Q)return J(this._coefficient);if(this._exponent<Q){let X=Q-this._exponent,Y=10n**BigInt(X),G=this._coefficient/Y,V=this._coefficient%Y,U=P.roundDivision(G,V,Y,Z);return J(U)}else{let X=this._exponent-Q,Y=this._coefficient*10n**BigInt(X);return J(Y)}}valueOf(){return this.toString()}}function wU($){return $ instanceof P}tZ.isDecimal=wU;tZ.Decimal={from($){if(typeof $==="bigint")return new P($,0);if(typeof $==="number"){if(!Number.isFinite($))throw Error("Number must be finite");return tZ.Decimal.from($.toString())}let Z=$.trim();if(Z==="")throw Error("Cannot parse empty string as Decimal");let J=/^([+-]?)(\d+)(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/.exec(Z);if(!J)throw Error(`Invalid decimal string: ${$}`);let Q=J[1]==="-"?-1n:1n,X=J[2]??"",Y=J[3]??"",G=J[4]?Number(J[4]):0;if(!Number.isSafeInteger(G)||G>x8||G<-x8)throw Error(`Exponent out of range: ${String(J[4])} exceeds safe integer bounds`);let V=X+Y,U=Q*BigInt(V),W=G-Y.length;if(!Number.isSafeInteger(W)||W>x8||W<-x8)throw Error(`Computed exponent out of range: ${String(W)} exceeds safe integer bounds`);return new P(U,W)},zero:new P(0n,0)}});var $1=K((eZ)=>{Object.defineProperty(eZ,"__esModule",{value:!0});eZ.coerceV2ResponseData=eZ.coerceV2RequestData=void 0;var OU=I8(),qU=($,Z)=>{if($==null)return $;switch(Z.kind){case"int64_string":return typeof $==="bigint"||typeof $==="number"?String($):$;case"decimal_string":return typeof $.toFixed==="function"&&typeof $.isZero==="function"?$.toString():$;case"object":{if(typeof $!=="object"||Array.isArray($))return $;let J=$,Q={};for(let X of Object.keys(J)){let Y=Z.fields[X];Q[X]=Y?eZ.coerceV2RequestData(J[X],Y):J[X]}return Q}case"array":{if(!Array.isArray($))return $;return $.map((J)=>eZ.coerceV2RequestData(J,Z.element))}case"nullable":return eZ.coerceV2RequestData($,Z.inner)}};eZ.coerceV2RequestData=qU;var EU=($,Z)=>{if($==null)return $;switch(Z.kind){case"int64_string":if(typeof $==="string")try{return BigInt($)}catch{throw Error(`Failed to coerce int64_string value: expected an integer string, got '${$}'`)}return $;case"decimal_string":if(typeof $==="string")try{return OU.Decimal.from($)}catch{throw Error(`Failed to coerce decimal_string value: expected a decimal string, got '${$}'`)}return $;case"object":{if(typeof $!=="object"||Array.isArray($))return $;let J=$;for(let Q of Object.keys(Z.fields))if(Q in J)J[Q]=eZ.coerceV2ResponseData(J[Q],Z.fields[Q]);return J}case"array":{if(!Array.isArray($))return $;for(let J=0;J<$.length;J++)$[J]=eZ.coerceV2ResponseData($[J],Z.element);return $}case"nullable":return eZ.coerceV2ResponseData($,Z.inner)}};eZ.coerceV2ResponseData=EU});var w=K((J1)=>{Object.defineProperty(J1,"__esModule",{value:!0});J1.StripeResource=void 0;var J0=c(),FU=sZ(),Z1=$1();m0.extend=J0.protoExtend;m0.method=FU.stripeMethod;m0.MAX_BUFFERED_REQUEST_METRICS=100;function m0($,Z){if(this._stripe=$,Z)throw Error("Support for curried url params was dropped in stripe-node v7.0.0. Instead, pass two ids.");this.basePath=(0,J0.makeURLInterpolator)(this.basePath||$.getApiField("basePath")),this.resourcePath=this.path,this.path=(0,J0.makeURLInterpolator)(this.path),this.initialize(...arguments)}J1.StripeResource=m0;m0.prototype={_stripe:null,path:"",resourcePath:"",basePath:null,initialize(){},requestDataProcessor:null,validateRequest:null,createFullPath($,Z){let J=[this.basePath(Z),this.path(Z)];if(typeof $==="function"){let Q=$(Z);if(Q)J.push(Q)}else J.push($);return this._joinUrlParts(J)},createResourcePathWithSymbols($){if($)return`/${this._joinUrlParts([this.resourcePath,$])}`;else return`/${this.resourcePath}`},_joinUrlParts($){return $.join("/").replace(/\/{2,}/g,"/")},_getRequestOpts($,Z,J){let Q=(Z.method||"GET").toUpperCase(),X=Z.usage||[],Y=Z.urlParams||[],G=Z.encode||((_)=>_),V=!!Z.fullPath,U=(0,J0.makeURLInterpolator)(V?Z.fullPath:Z.path||""),W=V?Z.fullPath:this.createResourcePathWithSymbols(Z.path),B=[].slice.call($),z=Y.reduce((_,P0)=>{let y=B.shift();if(typeof y!=="string")throw Error(`Stripe: Argument "${P0}" must be a string, but got: ${y} (on API request to \`${Q} ${W}\`)`);return _[P0]=y,_},{}),L=(0,J0.getDataFromArgs)(B),H=G(Object.assign({},L,J)),T=(0,J0.getOptionsFromArgs)(B),D=T.host||Z.host,q=!!Z.streaming||!!T.streaming;if(B.filter((_)=>_!=null).length)throw Error(`Stripe: Unknown arguments (${B}). Did you mean to pass an options object? See https://github.com/stripe/stripe-node/wiki/Passing-Options. (on API request to ${Q} \`${W}\`)`);let O=V?U(z):this.createFullPath(U,z),k=Object.assign(T.headers,Z.headers);if(Z.validator)Z.validator(H,{headers:k});let N=Z.method==="GET"||Z.method==="DELETE";return{requestMethod:Q,requestPath:O,bodyData:N?null:H,queryData:N?H:{},authenticator:T.authenticator??null,headers:k,host:D??null,streaming:q,settings:T.settings,usage:X}},_makeRequest($,Z,J){return new Promise((Q,X)=>{let Y;try{Y=this._getRequestOpts($,Z,J)}catch(z){X(z);return}if(Z.requestSchema&&Y.bodyData)Y.bodyData=(0,Z1.coerceV2RequestData)(Y.bodyData,Z.requestSchema);function G(z,L){if(z)X(z);else try{if(Z.responseSchema)(0,Z1.coerceV2ResponseData)(L,Z.responseSchema);Q(Z.transformResponseData?Z.transformResponseData(L):L)}catch(H){X(H)}}let V=Object.keys(Y.queryData).length===0,U=[Y.requestPath,V?"":"?",(0,J0.queryStringifyRequestData)(Y.queryData)].join(""),{headers:W,settings:B}=Y;this._stripe._requestSender._request(Y.requestMethod,Y.host,U,Y.bodyData,Y.authenticator,{headers:W,settings:B,streaming:Y.streaming},Y.usage,G,this.requestDataProcessor?.bind(this))})}}});var G1=K((X1)=>{Object.defineProperty(X1,"__esModule",{value:!0});X1.StripeContext=void 0;class T0{constructor($=[]){this._segments=[...$]}get segments(){return[...this._segments]}push($){if(!$)throw Error("Segment cannot be null or undefined");return new T0([...this._segments,$])}pop(){if(this._segments.length===0)throw Error("Cannot pop from an empty context");return new T0(this._segments.slice(0,-1))}toString(){return this._segments.join("/")}static parse($){if(!$)return new T0([]);return new T0($.split("/"))}}X1.StripeContext=T0});var W1=K((V1)=>{Object.defineProperty(V1,"__esModule",{value:!0});V1.createWebhooks=void 0;var o=M0(),CU=b0();function kU($){let Z={DEFAULT_TOLERANCE:300,signature:null,constructEvent(B,z,L,H,T,D){try{if(!this.signature)throw Error("ERR: missing signature helper, unable to verify");this.signature.verifyHeader(B,z,L,H||Z.DEFAULT_TOLERANCE,T,D)}catch(O){if(O instanceof CU.CryptoProviderOnlySupportsAsyncError)O.message+="\nUse `await constructEventAsync(...)` instead of `constructEvent(...)`";throw O}let q=B instanceof Uint8Array?JSON.parse(new TextDecoder("utf8").decode(B)):JSON.parse(B);if(q&&q.object==="v2.core.event")throw Error("You passed an event notification to stripe.webhooks.constructEvent, which expects a webhook payload. Use stripe.parseEventNotification instead.");return q},async constructEventAsync(B,z,L,H,T,D){if(!this.signature)throw Error("ERR: missing signature helper, unable to verify");await this.signature.verifyHeaderAsync(B,z,L,H||Z.DEFAULT_TOLERANCE,T,D);let q=B instanceof Uint8Array?JSON.parse(new TextDecoder("utf8").decode(B)):JSON.parse(B);if(q&&q.object==="v2.core.event")throw Error("You passed an event notification to stripe.webhooks.constructEvent, which expects a webhook payload. Use stripe.parseEventNotification instead.");return q},generateTestHeaderString:function(B){let z=W(B),L=z.signature||z.cryptoProvider.computeHMACSignature(z.payloadString,z.secret);return z.generateHeaderString(L)},generateTestHeaderStringAsync:async function(B){let z=W(B),L=z.signature||await z.cryptoProvider.computeHMACSignatureAsync(z.payloadString,z.secret);return z.generateHeaderString(L)}},J={EXPECTED_SCHEME:"v1",verifyHeader(B,z,L,H,T,D){let{decodedHeader:q,decodedPayload:O,details:k,suspectPayloadType:N}=X(B,z,this.EXPECTED_SCHEME),R=/\s/.test(L);T=T||U();let M=T.computeHMACSignature(Q(O,k),L);return Y(O,q,k,M,H,N,R,D),!0},async verifyHeaderAsync(B,z,L,H,T,D){let{decodedHeader:q,decodedPayload:O,details:k,suspectPayloadType:N}=X(B,z,this.EXPECTED_SCHEME),R=/\s/.test(L);T=T||U();let M=await T.computeHMACSignatureAsync(Q(O,k),L);return Y(O,q,k,M,H,N,R,D)}};function Q(B,z){return`${z.timestamp}.${B}`}function X(B,z,L){if(!B)throw new o.StripeSignatureVerificationError(z,B,{message:"No webhook payload was provided."});let H=typeof B!="string"&&!(B instanceof Uint8Array),T=new TextDecoder("utf8"),D=B instanceof Uint8Array?T.decode(B):B;if(Array.isArray(z))throw Error("Unexpected: An array was passed as a header, which should not be possible for the stripe-signature header.");if(z==null||z=="")throw new o.StripeSignatureVerificationError(z,B,{message:"No stripe-signature header value was provided."});let q=z instanceof Uint8Array?T.decode(z):z,O=G(q,L);if(!O||O.timestamp===-1)throw new o.StripeSignatureVerificationError(q,D,{message:"Unable to extract timestamp and signatures from header"});if(!O.signatures.length)throw new o.StripeSignatureVerificationError(q,D,{message:"No signatures found with expected scheme"});return{decodedPayload:D,decodedHeader:q,details:O,suspectPayloadType:H}}function Y(B,z,L,H,T,D,q,O){let k=!!L.signatures.filter($.secureCompare.bind($,H)).length,N=`
3
+ Learn more about webhook signing and explore webhook integration examples for various frameworks at https://docs.stripe.com/webhooks/signature`,R=q?`
4
4
 
5
- Note: The provided signing secret contains whitespace. This often indicates an extra newline or space is in the value`:"";if(!k){if(D)throw new s.StripeSignatureVerificationError(U,V,{message:`Webhook payload must be provided as a string or a Buffer (https://nodejs.org/api/buffer.html) instance representing the _raw_ request body.Payload was provided as a parsed JavaScript object instead.
5
+ Note: The provided signing secret contains whitespace. This often indicates an extra newline or space is in the value`:"";if(!k){if(D)throw new o.StripeSignatureVerificationError(z,B,{message:`Webhook payload must be provided as a string or a Buffer (https://nodejs.org/api/buffer.html) instance representing the _raw_ request body.Payload was provided as a parsed JavaScript object instead.
6
6
  Signature verification is impossible without access to the original signed material.
7
- `+I+`
8
- `+R});throw new s.StripeSignatureVerificationError(U,V,{message:`No signatures found matching the expected signature for payload. Are you passing the raw request body you received from Stripe?
7
+ `+N+`
8
+ `+R});throw new o.StripeSignatureVerificationError(z,B,{message:`No signatures found matching the expected signature for payload. Are you passing the raw request body you received from Stripe?
9
9
  If a webhook request is being forwarded by a third-party tool, ensure that the exact request body, including JSON formatting and new line style, is preserved.
10
- `+I+`
11
- `+R})}let M=Math.floor((typeof E==="number"?E:Date.now())/1000)-K.timestamp;if(w>0&&M>w)throw new s.StripeSignatureVerificationError(U,V,{message:"Timestamp outside the tolerance zone"});return!0}function G(V,U){if(typeof V!=="string")return null;return V.split(",").reduce((K,T)=>{let w=T.split("=");if(w[0]==="t")K.timestamp=parseInt(w[1],10);if(w[0]===U)K.signatures.push(w[1]);return K},{timestamp:-1,signatures:[]})}let W=null;function L(){if(!W)W=$.createDefaultCryptoProvider();return W}function B(V){if(!V)throw new s.StripeError({message:"Options are required"});let U=Math.floor(V.timestamp)||Math.floor(Date.now()/1000),K=V.scheme||J.EXPECTED_SCHEME,T=V.cryptoProvider||L(),w=`${U}.${V.payload}`;return{...V,timestamp:U,scheme:K,cryptoProvider:T,payloadString:w,generateHeaderString:(C)=>{return`t=${U},${K}=${C}`}}}return Z.signature=J,Z}aZ.createWebhooks=KT});var eZ=z((rZ)=>{Object.defineProperty(rZ,"__esModule",{value:!0});rZ.ApiVersion=void 0;rZ.ApiVersion="2026-03-25.preview"});var J6=z(($6)=>{Object.defineProperty($6,"__esModule",{value:!0});$6.resourceNamespace=void 0;function HT($,Z){for(let J in Z){if(!Object.prototype.hasOwnProperty.call(Z,J))continue;let Y=J[0].toLowerCase()+J.substring(1),X=new Z[J]($);this[Y]=X}}function TT($,Z){return function(J){return new HT(J,Z)}}$6.resourceNamespace=TT});var G6=z((X6)=>{Object.defineProperty(X6,"__esModule",{value:!0});X6.AccountLinks=void 0;var Y6=H(),wT=Y6.StripeResource.method;X6.AccountLinks=Y6.StripeResource.extend({create:wT({method:"POST",fullPath:"/v2/core/account_links"})})});var U6=z((B6)=>{Object.defineProperty(B6,"__esModule",{value:!0});B6.AccountTokens=void 0;var V6=H(),W6=V6.StripeResource.method;B6.AccountTokens=V6.StripeResource.extend({create:W6({method:"POST",fullPath:"/v2/core/account_tokens",requestSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}}),retrieve:W6({method:"GET",fullPath:"/v2/core/account_tokens/{id}"})})});var T6=z((K6)=>{Object.defineProperty(K6,"__esModule",{value:!0});K6.Accounts=void 0;var z6=H(),o=z6.StripeResource.method;K6.Accounts=z6.StripeResource.extend({retrieve:o({method:"GET",fullPath:"/v1/financial_connections/accounts/{account}"}),list:o({method:"GET",fullPath:"/v1/financial_connections/accounts",methodType:"list"}),disconnect:o({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/disconnect"}),listInferredBalances:o({method:"GET",fullPath:"/v1/financial_connections/accounts/{account}/inferred_balances",methodType:"list"}),listOwners:o({method:"GET",fullPath:"/v1/financial_connections/accounts/{account}/owners",methodType:"list"}),refresh:o({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/refresh"}),subscribe:o({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/subscribe"}),unsubscribe:o({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/unsubscribe"})})});var q6=z((D6)=>{Object.defineProperty(D6,"__esModule",{value:!0});D6.Persons=void 0;var w6=H(),p0=w6.StripeResource.method;D6.Persons=w6.StripeResource.extend({create:p0({method:"POST",fullPath:"/v2/core/accounts/{account_id}/persons",requestSchema:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}},responseSchema:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}),retrieve:p0({method:"GET",fullPath:"/v2/core/accounts/{account_id}/persons/{id}",responseSchema:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}),update:p0({method:"POST",fullPath:"/v2/core/accounts/{account_id}/persons/{id}",requestSchema:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}},responseSchema:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}),list:p0({method:"GET",fullPath:"/v2/core/accounts/{account_id}/persons",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}),del:p0({method:"DELETE",fullPath:"/v2/core/accounts/{account_id}/persons/{id}"})})});var x6=z((F6)=>{Object.defineProperty(F6,"__esModule",{value:!0});F6.PersonTokens=void 0;var C6=H(),E6=C6.StripeResource.method;F6.PersonTokens=C6.StripeResource.extend({create:E6({method:"POST",fullPath:"/v2/core/accounts/{account_id}/person_tokens",requestSchema:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}),retrieve:E6({method:"GET",fullPath:"/v2/core/accounts/{account_id}/person_tokens/{id}"})})});var I6=z((A6)=>{Object.defineProperty(A6,"__esModule",{value:!0});A6.Accounts=void 0;var k9=H(),DT=q6(),OT=x6(),d0=k9.StripeResource.method;A6.Accounts=k9.StripeResource.extend({constructor:function(...$){k9.StripeResource.apply(this,$),this.persons=new DT.Persons(...$),this.personTokens=new OT.PersonTokens(...$)},create:d0({method:"POST",fullPath:"/v2/core/accounts",requestSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}},responseSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}}),retrieve:d0({method:"GET",fullPath:"/v2/core/accounts/{id}",responseSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}}),update:d0({method:"POST",fullPath:"/v2/core/accounts/{id}",requestSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}},responseSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}}),list:d0({method:"GET",fullPath:"/v2/core/accounts",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}}}}}),close:d0({method:"POST",fullPath:"/v2/core/accounts/{id}/close",responseSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}})})});var R6=z((y6)=>{Object.defineProperty(y6,"__esModule",{value:!0});y6.ActiveEntitlements=void 0;var v6=H(),P6=v6.StripeResource.method;y6.ActiveEntitlements=v6.StripeResource.extend({retrieve:P6({method:"GET",fullPath:"/v1/entitlements/active_entitlements/{id}"}),list:P6({method:"GET",fullPath:"/v1/entitlements/active_entitlements",methodType:"list"})})});var g6=z((f6)=>{Object.defineProperty(f6,"__esModule",{value:!0});f6.Adjustments=void 0;var j6=H(),b6=j6.StripeResource.method;f6.Adjustments=j6.StripeResource.extend({retrieve:b6({method:"GET",fullPath:"/v2/money_management/adjustments/{id}"}),list:b6({method:"GET",fullPath:"/v2/money_management/adjustments",methodType:"list"})})});var u6=z((h6)=>{Object.defineProperty(h6,"__esModule",{value:!0});h6.Alerts=void 0;var M6=H(),E0=M6.StripeResource.method;h6.Alerts=M6.StripeResource.extend({create:E0({method:"POST",fullPath:"/v1/billing/alerts"}),retrieve:E0({method:"GET",fullPath:"/v1/billing/alerts/{id}"}),list:E0({method:"GET",fullPath:"/v1/billing/alerts",methodType:"list"}),activate:E0({method:"POST",fullPath:"/v1/billing/alerts/{id}/activate"}),archive:E0({method:"POST",fullPath:"/v1/billing/alerts/{id}/archive"}),deactivate:E0({method:"POST",fullPath:"/v1/billing/alerts/{id}/deactivate"})})});var p6=z((l6)=>{Object.defineProperty(l6,"__esModule",{value:!0});l6.Associations=void 0;var c6=H(),qT=c6.StripeResource.method;l6.Associations=c6.StripeResource.extend({find:qT({method:"GET",fullPath:"/v1/tax/associations/find"})})});var s6=z((i6)=>{Object.defineProperty(i6,"__esModule",{value:!0});i6.Authorizations=void 0;var d6=H(),ET=d6.StripeResource.method;i6.Authorizations=d6.StripeResource.extend({retrieve:ET({method:"GET",fullPath:"/v1/financial_connections/authorizations/{authorization}"})})});var e6=z((r6)=>{Object.defineProperty(r6,"__esModule",{value:!0});r6.Authorizations=void 0;var o6=H(),i0=o6.StripeResource.method;r6.Authorizations=o6.StripeResource.extend({retrieve:i0({method:"GET",fullPath:"/v1/issuing/authorizations/{authorization}",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),update:i0({method:"POST",fullPath:"/v1/issuing/authorizations/{authorization}",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),list:i0({method:"GET",fullPath:"/v1/issuing/authorizations",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}}}}),approve:i0({method:"POST",fullPath:"/v1/issuing/authorizations/{authorization}/approve",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),decline:i0({method:"POST",fullPath:"/v1/issuing/authorizations/{authorization}/decline",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}})})});var Y1=z((Z1)=>{Object.defineProperty(Z1,"__esModule",{value:!0});Z1.Authorizations=void 0;var $1=H(),Q0=$1.StripeResource.method;Z1.Authorizations=$1.StripeResource.extend({create:Q0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations",requestSchema:{kind:"object",fields:{fleet:{kind:"object",fields:{reported_breakdown:{kind:"object",fields:{fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},non_fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},tax:{kind:"object",fields:{local_amount_decimal:{kind:"decimal_string"},national_amount_decimal:{kind:"decimal_string"}}}}}}},fuel:{kind:"object",fields:{quantity_decimal:{kind:"decimal_string"},unit_cost_decimal:{kind:"decimal_string"}}}}},responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),capture:Q0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/capture",requestSchema:{kind:"object",fields:{purchase_details:{kind:"object",fields:{fleet:{kind:"object",fields:{reported_breakdown:{kind:"object",fields:{fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},non_fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},tax:{kind:"object",fields:{local_amount_decimal:{kind:"decimal_string"},national_amount_decimal:{kind:"decimal_string"}}}}}}},fuel:{kind:"object",fields:{quantity_decimal:{kind:"decimal_string"},unit_cost_decimal:{kind:"decimal_string"}}},receipt:{kind:"array",element:{kind:"object",fields:{quantity:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),expire:Q0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/expire",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),finalizeAmount:Q0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/finalize_amount",requestSchema:{kind:"object",fields:{fleet:{kind:"object",fields:{reported_breakdown:{kind:"object",fields:{fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},non_fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},tax:{kind:"object",fields:{local_amount_decimal:{kind:"decimal_string"},national_amount_decimal:{kind:"decimal_string"}}}}}}},fuel:{kind:"object",fields:{quantity_decimal:{kind:"decimal_string"},unit_cost_decimal:{kind:"decimal_string"}}}}},responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),increment:Q0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/increment",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),respond:Q0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/fraud_challenges/respond",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),reverse:Q0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/reverse",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}})})});var W1=z((Q1)=>{Object.defineProperty(Q1,"__esModule",{value:!0});Q1.BatchJobs=void 0;var X1=H(),x9=X1.StripeResource.method;Q1.BatchJobs=X1.StripeResource.extend({create:x9({method:"POST",fullPath:"/v2/core/batch_jobs",responseSchema:{kind:"object",fields:{status_details:{kind:"object",fields:{canceled:{kind:"object",fields:{failure_count:{kind:"int64_string"},output_file:{kind:"object",fields:{size:{kind:"int64_string"}}},success_count:{kind:"int64_string"}}},complete:{kind:"object",fields:{failure_count:{kind:"int64_string"},output_file:{kind:"object",fields:{size:{kind:"int64_string"}}},success_count:{kind:"int64_string"}}},in_progress:{kind:"object",fields:{failure_count:{kind:"int64_string"},success_count:{kind:"int64_string"}}},timeout:{kind:"object",fields:{failure_count:{kind:"int64_string"},output_file:{kind:"object",fields:{size:{kind:"int64_string"}}},success_count:{kind:"int64_string"}}},validating:{kind:"object",fields:{validated_count:{kind:"int64_string"}}},validation_failed:{kind:"object",fields:{failure_count:{kind:"int64_string"},output_file:{kind:"object",fields:{size:{kind:"int64_string"}}},success_count:{kind:"int64_string"}}}}}}}}),retrieve:x9({method:"GET",fullPath:"/v2/core/batch_jobs/{id}",responseSchema:{kind:"object",fields:{status_details:{kind:"object",fields:{canceled:{kind:"object",fields:{failure_count:{kind:"int64_string"},output_file:{kind:"object",fields:{size:{kind:"int64_string"}}},success_count:{kind:"int64_string"}}},complete:{kind:"object",fields:{failure_count:{kind:"int64_string"},output_file:{kind:"object",fields:{size:{kind:"int64_string"}}},success_count:{kind:"int64_string"}}},in_progress:{kind:"object",fields:{failure_count:{kind:"int64_string"},success_count:{kind:"int64_string"}}},timeout:{kind:"object",fields:{failure_count:{kind:"int64_string"},output_file:{kind:"object",fields:{size:{kind:"int64_string"}}},success_count:{kind:"int64_string"}}},validating:{kind:"object",fields:{validated_count:{kind:"int64_string"}}},validation_failed:{kind:"object",fields:{failure_count:{kind:"int64_string"},output_file:{kind:"object",fields:{size:{kind:"int64_string"}}},success_count:{kind:"int64_string"}}}}}}}}),cancel:x9({method:"POST",fullPath:"/v2/core/batch_jobs/{id}/cancel",responseSchema:{kind:"object",fields:{status_details:{kind:"object",fields:{canceled:{kind:"object",fields:{failure_count:{kind:"int64_string"},output_file:{kind:"object",fields:{size:{kind:"int64_string"}}},success_count:{kind:"int64_string"}}},complete:{kind:"object",fields:{failure_count:{kind:"int64_string"},output_file:{kind:"object",fields:{size:{kind:"int64_string"}}},success_count:{kind:"int64_string"}}},in_progress:{kind:"object",fields:{failure_count:{kind:"int64_string"},success_count:{kind:"int64_string"}}},timeout:{kind:"object",fields:{failure_count:{kind:"int64_string"},output_file:{kind:"object",fields:{size:{kind:"int64_string"}}},success_count:{kind:"int64_string"}}},validating:{kind:"object",fields:{validated_count:{kind:"int64_string"}}},validation_failed:{kind:"object",fields:{failure_count:{kind:"int64_string"},output_file:{kind:"object",fields:{size:{kind:"int64_string"}}},success_count:{kind:"int64_string"}}}}}}}})})});var z1=z((L1)=>{Object.defineProperty(L1,"__esModule",{value:!0});L1.Versions=void 0;var B1=H(),V1=B1.StripeResource.method;L1.Versions=B1.StripeResource.extend({retrieve:V1({method:"GET",fullPath:"/v2/billing/bill_settings/{bill_setting_id}/versions/{id}"}),list:V1({method:"GET",fullPath:"/v2/billing/bill_settings/{bill_setting_id}/versions",methodType:"list"})})});var T1=z((K1)=>{Object.defineProperty(K1,"__esModule",{value:!0});K1.BillSettings=void 0;var A9=H(),CT=z1(),g8=A9.StripeResource.method;K1.BillSettings=A9.StripeResource.extend({constructor:function(...$){A9.StripeResource.apply(this,$),this.versions=new CT.Versions(...$)},create:g8({method:"POST",fullPath:"/v2/billing/bill_settings"}),retrieve:g8({method:"GET",fullPath:"/v2/billing/bill_settings/{id}"}),update:g8({method:"POST",fullPath:"/v2/billing/bill_settings/{id}"}),list:g8({method:"GET",fullPath:"/v2/billing/bill_settings",methodType:"list"})})});var q1=z((D1)=>{Object.defineProperty(D1,"__esModule",{value:!0});D1.Cadences=void 0;var w1=H(),a0=w1.StripeResource.method;D1.Cadences=w1.StripeResource.extend({create:a0({method:"POST",fullPath:"/v2/billing/cadences",responseSchema:{kind:"object",fields:{settings_data:{kind:"object",fields:{collection:{kind:"object",fields:{payment_method_options:{kind:"object",fields:{card:{kind:"object",fields:{mandate_options:{kind:"object",fields:{amount:{kind:"int64_string"}}}}}}}}}}}}}}),retrieve:a0({method:"GET",fullPath:"/v2/billing/cadences/{id}",responseSchema:{kind:"object",fields:{settings_data:{kind:"object",fields:{collection:{kind:"object",fields:{payment_method_options:{kind:"object",fields:{card:{kind:"object",fields:{mandate_options:{kind:"object",fields:{amount:{kind:"int64_string"}}}}}}}}}}}}}}),update:a0({method:"POST",fullPath:"/v2/billing/cadences/{id}",responseSchema:{kind:"object",fields:{settings_data:{kind:"object",fields:{collection:{kind:"object",fields:{payment_method_options:{kind:"object",fields:{card:{kind:"object",fields:{mandate_options:{kind:"object",fields:{amount:{kind:"int64_string"}}}}}}}}}}}}}}),list:a0({method:"GET",fullPath:"/v2/billing/cadences",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{settings_data:{kind:"object",fields:{collection:{kind:"object",fields:{payment_method_options:{kind:"object",fields:{card:{kind:"object",fields:{mandate_options:{kind:"object",fields:{amount:{kind:"int64_string"}}}}}}}}}}}}}}}}}),cancel:a0({method:"POST",fullPath:"/v2/billing/cadences/{id}/cancel",responseSchema:{kind:"object",fields:{settings_data:{kind:"object",fields:{collection:{kind:"object",fields:{payment_method_options:{kind:"object",fields:{card:{kind:"object",fields:{mandate_options:{kind:"object",fields:{amount:{kind:"int64_string"}}}}}}}}}}}}}})})});var k1=z((C1)=>{Object.defineProperty(C1,"__esModule",{value:!0});C1.Calculations=void 0;var E1=H(),N9=E1.StripeResource.method;C1.Calculations=E1.StripeResource.extend({create:N9({method:"POST",fullPath:"/v1/tax/calculations"}),retrieve:N9({method:"GET",fullPath:"/v1/tax/calculations/{calculation}"}),listLineItems:N9({method:"GET",fullPath:"/v1/tax/calculations/{calculation}/line_items",methodType:"list"})})});var I1=z((A1)=>{Object.defineProperty(A1,"__esModule",{value:!0});A1.Cardholders=void 0;var x1=H(),M8=x1.StripeResource.method;A1.Cardholders=x1.StripeResource.extend({create:M8({method:"POST",fullPath:"/v1/issuing/cardholders"}),retrieve:M8({method:"GET",fullPath:"/v1/issuing/cardholders/{cardholder}"}),update:M8({method:"POST",fullPath:"/v1/issuing/cardholders/{cardholder}"}),list:M8({method:"GET",fullPath:"/v1/issuing/cardholders",methodType:"list"})})});var S1=z((v1)=>{Object.defineProperty(v1,"__esModule",{value:!0});v1.Cards=void 0;var P1=H(),h8=P1.StripeResource.method;v1.Cards=P1.StripeResource.extend({create:h8({method:"POST",fullPath:"/v1/issuing/cards"}),retrieve:h8({method:"GET",fullPath:"/v1/issuing/cards/{card}"}),update:h8({method:"POST",fullPath:"/v1/issuing/cards/{card}"}),list:h8({method:"GET",fullPath:"/v1/issuing/cards",methodType:"list"})})});var f1=z((b1)=>{Object.defineProperty(b1,"__esModule",{value:!0});b1.Cards=void 0;var R1=H(),s0=R1.StripeResource.method;b1.Cards=R1.StripeResource.extend({deliverCard:s0({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/deliver"}),failCard:s0({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/fail"}),returnCard:s0({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/return"}),shipCard:s0({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/ship"}),submitCard:s0({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/submit"})})});var m1=z((M1)=>{Object.defineProperty(M1,"__esModule",{value:!0});M1.Versions=void 0;var g1=H(),_1=g1.StripeResource.method;M1.Versions=g1.StripeResource.extend({retrieve:_1({method:"GET",fullPath:"/v2/billing/collection_settings/{collection_setting_id}/versions/{id}",responseSchema:{kind:"object",fields:{payment_method_options:{kind:"object",fields:{card:{kind:"object",fields:{mandate_options:{kind:"object",fields:{amount:{kind:"int64_string"}}}}}}}}}}),list:_1({method:"GET",fullPath:"/v2/billing/collection_settings/{collection_setting_id}/versions",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{payment_method_options:{kind:"object",fields:{card:{kind:"object",fields:{mandate_options:{kind:"object",fields:{amount:{kind:"int64_string"}}}}}}}}}}}}})})});var l1=z((u1)=>{Object.defineProperty(u1,"__esModule",{value:!0});u1.CollectionSettings=void 0;var I9=H(),FT=m1(),m8=I9.StripeResource.method;u1.CollectionSettings=I9.StripeResource.extend({constructor:function(...$){I9.StripeResource.apply(this,$),this.versions=new FT.Versions(...$)},create:m8({method:"POST",fullPath:"/v2/billing/collection_settings",requestSchema:{kind:"object",fields:{payment_method_options:{kind:"object",fields:{card:{kind:"object",fields:{mandate_options:{kind:"object",fields:{amount:{kind:"int64_string"}}}}}}}}},responseSchema:{kind:"object",fields:{payment_method_options:{kind:"object",fields:{card:{kind:"object",fields:{mandate_options:{kind:"object",fields:{amount:{kind:"int64_string"}}}}}}}}}}),retrieve:m8({method:"GET",fullPath:"/v2/billing/collection_settings/{id}",responseSchema:{kind:"object",fields:{payment_method_options:{kind:"object",fields:{card:{kind:"object",fields:{mandate_options:{kind:"object",fields:{amount:{kind:"int64_string"}}}}}}}}}}),update:m8({method:"POST",fullPath:"/v2/billing/collection_settings/{id}",requestSchema:{kind:"object",fields:{payment_method_options:{kind:"object",fields:{card:{kind:"object",fields:{mandate_options:{kind:"object",fields:{amount:{kind:"int64_string"}}}}}}}}},responseSchema:{kind:"object",fields:{payment_method_options:{kind:"object",fields:{card:{kind:"object",fields:{mandate_options:{kind:"object",fields:{amount:{kind:"int64_string"}}}}}}}}}}),list:m8({method:"GET",fullPath:"/v2/billing/collection_settings",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{payment_method_options:{kind:"object",fields:{card:{kind:"object",fields:{mandate_options:{kind:"object",fields:{amount:{kind:"int64_string"}}}}}}}}}}}}})})});var i1=z((p1)=>{Object.defineProperty(p1,"__esModule",{value:!0});p1.Configurations=void 0;var n1=H(),u8=n1.StripeResource.method;p1.Configurations=n1.StripeResource.extend({create:u8({method:"POST",fullPath:"/v1/billing_portal/configurations"}),retrieve:u8({method:"GET",fullPath:"/v1/billing_portal/configurations/{configuration}"}),update:u8({method:"POST",fullPath:"/v1/billing_portal/configurations/{configuration}"}),list:u8({method:"GET",fullPath:"/v1/billing_portal/configurations",methodType:"list"})})});var r1=z((s1)=>{Object.defineProperty(s1,"__esModule",{value:!0});s1.Configurations=void 0;var a1=H(),o0=a1.StripeResource.method;s1.Configurations=a1.StripeResource.extend({create:o0({method:"POST",fullPath:"/v1/terminal/configurations"}),retrieve:o0({method:"GET",fullPath:"/v1/terminal/configurations/{configuration}"}),update:o0({method:"POST",fullPath:"/v1/terminal/configurations/{configuration}"}),list:o0({method:"GET",fullPath:"/v1/terminal/configurations",methodType:"list"}),del:o0({method:"DELETE",fullPath:"/v1/terminal/configurations/{configuration}"})})});var Z7=z((e1)=>{Object.defineProperty(e1,"__esModule",{value:!0});e1.ConfirmationTokens=void 0;var t1=H(),kT=t1.StripeResource.method;e1.ConfirmationTokens=t1.StripeResource.extend({create:kT({method:"POST",fullPath:"/v1/test_helpers/confirmation_tokens"})})});var Q7=z((Y7)=>{Object.defineProperty(Y7,"__esModule",{value:!0});Y7.ConnectionTokens=void 0;var J7=H(),xT=J7.StripeResource.method;Y7.ConnectionTokens=J7.StripeResource.extend({create:xT({method:"POST",fullPath:"/v1/terminal/connection_tokens"})})});var B7=z((W7)=>{Object.defineProperty(W7,"__esModule",{value:!0});W7.CreditBalanceSummary=void 0;var G7=H(),AT=G7.StripeResource.method;W7.CreditBalanceSummary=G7.StripeResource.extend({retrieve:AT({method:"GET",fullPath:"/v1/billing/credit_balance_summary"})})});var H7=z((z7)=>{Object.defineProperty(z7,"__esModule",{value:!0});z7.CreditBalanceTransactions=void 0;var U7=H(),L7=U7.StripeResource.method;z7.CreditBalanceTransactions=U7.StripeResource.extend({retrieve:L7({method:"GET",fullPath:"/v1/billing/credit_balance_transactions/{id}"}),list:L7({method:"GET",fullPath:"/v1/billing/credit_balance_transactions",methodType:"list"})})});var O7=z((w7)=>{Object.defineProperty(w7,"__esModule",{value:!0});w7.CreditGrants=void 0;var T7=H(),C0=T7.StripeResource.method;w7.CreditGrants=T7.StripeResource.extend({create:C0({method:"POST",fullPath:"/v1/billing/credit_grants"}),retrieve:C0({method:"GET",fullPath:"/v1/billing/credit_grants/{id}"}),update:C0({method:"POST",fullPath:"/v1/billing/credit_grants/{id}"}),list:C0({method:"GET",fullPath:"/v1/billing/credit_grants",methodType:"list"}),expire:C0({method:"POST",fullPath:"/v1/billing/credit_grants/{id}/expire"}),voidGrant:C0({method:"POST",fullPath:"/v1/billing/credit_grants/{id}/void"})})});var F7=z((E7)=>{Object.defineProperty(E7,"__esModule",{value:!0});E7.CreditReversals=void 0;var q7=H(),P9=q7.StripeResource.method;E7.CreditReversals=q7.StripeResource.extend({create:P9({method:"POST",fullPath:"/v1/treasury/credit_reversals"}),retrieve:P9({method:"GET",fullPath:"/v1/treasury/credit_reversals/{credit_reversal}"}),list:P9({method:"GET",fullPath:"/v1/treasury/credit_reversals",methodType:"list"})})});var N7=z((x7)=>{Object.defineProperty(x7,"__esModule",{value:!0});x7.CreditUnderwritingRecords=void 0;var k7=H(),F0=k7.StripeResource.method;x7.CreditUnderwritingRecords=k7.StripeResource.extend({retrieve:F0({method:"GET",fullPath:"/v1/issuing/credit_underwriting_records/{credit_underwriting_record}"}),list:F0({method:"GET",fullPath:"/v1/issuing/credit_underwriting_records",methodType:"list"}),correct:F0({method:"POST",fullPath:"/v1/issuing/credit_underwriting_records/{credit_underwriting_record}/correct"}),createFromApplication:F0({method:"POST",fullPath:"/v1/issuing/credit_underwriting_records/create_from_application"}),createFromProactiveReview:F0({method:"POST",fullPath:"/v1/issuing/credit_underwriting_records/create_from_proactive_review"}),reportDecision:F0({method:"POST",fullPath:"/v1/issuing/credit_underwriting_records/{credit_underwriting_record}/report_decision"})})});var y7=z((P7)=>{Object.defineProperty(P7,"__esModule",{value:!0});P7.Customers=void 0;var I7=H(),NT=I7.StripeResource.method;P7.Customers=I7.StripeResource.extend({fundCashBalance:NT({method:"POST",fullPath:"/v1/test_helpers/customers/{customer}/fund_cash_balance"})})});var j7=z((R7)=>{Object.defineProperty(R7,"__esModule",{value:!0});R7.DebitReversals=void 0;var S7=H(),v9=S7.StripeResource.method;R7.DebitReversals=S7.StripeResource.extend({create:v9({method:"POST",fullPath:"/v1/treasury/debit_reversals"}),retrieve:v9({method:"GET",fullPath:"/v1/treasury/debit_reversals/{debit_reversal}"}),list:v9({method:"GET",fullPath:"/v1/treasury/debit_reversals",methodType:"list"})})});var h7=z((g7)=>{Object.defineProperty(g7,"__esModule",{value:!0});g7.DisputeSettlementDetails=void 0;var _7=H(),f7=_7.StripeResource.method;g7.DisputeSettlementDetails=_7.StripeResource.extend({retrieve:f7({method:"GET",fullPath:"/v1/issuing/dispute_settlement_details/{dispute_settlement_detail}"}),list:f7({method:"GET",fullPath:"/v1/issuing/dispute_settlement_details",methodType:"list"})})});var l7=z((u7)=>{Object.defineProperty(u7,"__esModule",{value:!0});u7.Disputes=void 0;var m7=H(),r0=m7.StripeResource.method;u7.Disputes=m7.StripeResource.extend({create:r0({method:"POST",fullPath:"/v1/issuing/disputes"}),retrieve:r0({method:"GET",fullPath:"/v1/issuing/disputes/{dispute}"}),update:r0({method:"POST",fullPath:"/v1/issuing/disputes/{dispute}"}),list:r0({method:"GET",fullPath:"/v1/issuing/disputes",methodType:"list"}),submit:r0({method:"POST",fullPath:"/v1/issuing/disputes/{dispute}/submit"})})});var a7=z((d7)=>{Object.defineProperty(d7,"__esModule",{value:!0});d7.EarlyFraudWarnings=void 0;var p7=H(),n7=p7.StripeResource.method;d7.EarlyFraudWarnings=p7.StripeResource.extend({retrieve:n7({method:"GET",fullPath:"/v1/radar/early_fraud_warnings/{early_fraud_warning}"}),list:n7({method:"GET",fullPath:"/v1/radar/early_fraud_warnings",methodType:"list"})})});var t7=z((o7)=>{Object.defineProperty(o7,"__esModule",{value:!0});o7.EventDestinations=void 0;var s7=H(),r=s7.StripeResource.method;o7.EventDestinations=s7.StripeResource.extend({create:r({method:"POST",fullPath:"/v2/core/event_destinations"}),retrieve:r({method:"GET",fullPath:"/v2/core/event_destinations/{id}"}),update:r({method:"POST",fullPath:"/v2/core/event_destinations/{id}"}),list:r({method:"GET",fullPath:"/v2/core/event_destinations",methodType:"list"}),del:r({method:"DELETE",fullPath:"/v2/core/event_destinations/{id}"}),disable:r({method:"POST",fullPath:"/v2/core/event_destinations/{id}/disable"}),enable:r({method:"POST",fullPath:"/v2/core/event_destinations/{id}/enable"}),ping:r({method:"POST",fullPath:"/v2/core/event_destinations/{id}/ping"})})});var J5=z(($5)=>{Object.defineProperty($5,"__esModule",{value:!0});$5.Events=void 0;var e7=H(),y9=e7.StripeResource.method;$5.Events=e7.StripeResource.extend({retrieve(...$){return y9({method:"GET",fullPath:"/v2/core/events/{id}",transformResponseData:(J)=>{return this.addFetchRelatedObjectIfNeeded(J)}}).apply(this,$)},list(...$){return y9({method:"GET",fullPath:"/v2/core/events",methodType:"list",transformResponseData:(J)=>{return{...J,data:J.data.map(this.addFetchRelatedObjectIfNeeded.bind(this))}}}).apply(this,$)},addFetchRelatedObjectIfNeeded($){if(!$.related_object||!$.related_object.url)return $;return{...$,fetchRelatedObject:()=>y9({method:"GET",fullPath:$.related_object.url}).apply(this,[{stripeContext:$.context,headers:{"Stripe-Request-Trigger":`event=${$.id}`}}])}}})});var G5=z((X5)=>{Object.defineProperty(X5,"__esModule",{value:!0});X5.Features=void 0;var Y5=H(),c8=Y5.StripeResource.method;X5.Features=Y5.StripeResource.extend({create:c8({method:"POST",fullPath:"/v1/entitlements/features"}),retrieve:c8({method:"GET",fullPath:"/v1/entitlements/features/{id}"}),update:c8({method:"POST",fullPath:"/v1/entitlements/features/{id}"}),list:c8({method:"GET",fullPath:"/v1/entitlements/features",methodType:"list"})})});var L5=z((V5)=>{Object.defineProperty(V5,"__esModule",{value:!0});V5.FinancialAccounts=void 0;var W5=H(),G0=W5.StripeResource.method;V5.FinancialAccounts=W5.StripeResource.extend({create:G0({method:"POST",fullPath:"/v1/treasury/financial_accounts"}),retrieve:G0({method:"GET",fullPath:"/v1/treasury/financial_accounts/{financial_account}"}),update:G0({method:"POST",fullPath:"/v1/treasury/financial_accounts/{financial_account}"}),list:G0({method:"GET",fullPath:"/v1/treasury/financial_accounts",methodType:"list"}),close:G0({method:"POST",fullPath:"/v1/treasury/financial_accounts/{financial_account}/close"}),retrieveFeatures:G0({method:"GET",fullPath:"/v1/treasury/financial_accounts/{financial_account}/features"}),updateFeatures:G0({method:"POST",fullPath:"/v1/treasury/financial_accounts/{financial_account}/features"})})});var H5=z((z5)=>{Object.defineProperty(z5,"__esModule",{value:!0});z5.FinancialAccounts=void 0;var U5=H(),t0=U5.StripeResource.method;z5.FinancialAccounts=U5.StripeResource.extend({create:t0({method:"POST",fullPath:"/v2/money_management/financial_accounts"}),retrieve:t0({method:"GET",fullPath:"/v2/money_management/financial_accounts/{id}"}),update:t0({method:"POST",fullPath:"/v2/money_management/financial_accounts/{id}"}),list:t0({method:"GET",fullPath:"/v2/money_management/financial_accounts",methodType:"list"}),close:t0({method:"POST",fullPath:"/v2/money_management/financial_accounts/{id}/close"})})});var O5=z((w5)=>{Object.defineProperty(w5,"__esModule",{value:!0});w5.FinancialAddresses=void 0;var T5=H(),S9=T5.StripeResource.method;w5.FinancialAddresses=T5.StripeResource.extend({create:S9({method:"POST",fullPath:"/v2/money_management/financial_addresses"}),retrieve:S9({method:"GET",fullPath:"/v2/money_management/financial_addresses/{id}"}),list:S9({method:"GET",fullPath:"/v2/money_management/financial_addresses",methodType:"list"})})});var k5=z((C5)=>{Object.defineProperty(C5,"__esModule",{value:!0});C5.FinancialAddresses=void 0;var E5=H(),q5=E5.StripeResource.method;C5.FinancialAddresses=E5.StripeResource.extend({credit:q5({method:"POST",fullPath:"/v2/test_helpers/financial_addresses/{id}/credit"}),generateMicrodeposits:q5({method:"POST",fullPath:"/v2/test_helpers/financial_addresses/{id}/generate_microdeposits"})})});var I5=z((A5)=>{Object.defineProperty(A5,"__esModule",{value:!0});A5.FinancingOffers=void 0;var x5=H(),R9=x5.StripeResource.method;A5.FinancingOffers=x5.StripeResource.extend({retrieve:R9({method:"GET",fullPath:"/v1/capital/financing_offers/{financing_offer}"}),list:R9({method:"GET",fullPath:"/v1/capital/financing_offers",methodType:"list"}),markDelivered:R9({method:"POST",fullPath:"/v1/capital/financing_offers/{financing_offer}/mark_delivered"})})});var S5=z((v5)=>{Object.defineProperty(v5,"__esModule",{value:!0});v5.FinancingSummary=void 0;var P5=H(),IT=P5.StripeResource.method;v5.FinancingSummary=P5.StripeResource.extend({retrieve:IT({method:"GET",fullPath:"/v1/capital/financing_summary"})})});var _5=z((j5)=>{Object.defineProperty(j5,"__esModule",{value:!0});j5.FinancingTransactions=void 0;var b5=H(),R5=b5.StripeResource.method;j5.FinancingTransactions=b5.StripeResource.extend({retrieve:R5({method:"GET",fullPath:"/v1/capital/financing_transactions/{financing_transaction}"}),list:R5({method:"GET",fullPath:"/v1/capital/financing_transactions",methodType:"list"})})});var m5=z((M5)=>{Object.defineProperty(M5,"__esModule",{value:!0});M5.Forms=void 0;var g5=H(),b9=g5.StripeResource.method;M5.Forms=g5.StripeResource.extend({retrieve:b9({method:"GET",fullPath:"/v1/tax/forms/{id}"}),list:b9({method:"GET",fullPath:"/v1/tax/forms",methodType:"list"}),pdf:b9({method:"GET",fullPath:"/v1/tax/forms/{id}/pdf",host:"files.stripe.com",streaming:!0})})});var p5=z((l5)=>{Object.defineProperty(l5,"__esModule",{value:!0});l5.FraudLiabilityDebits=void 0;var c5=H(),u5=c5.StripeResource.method;l5.FraudLiabilityDebits=c5.StripeResource.extend({retrieve:u5({method:"GET",fullPath:"/v1/issuing/fraud_liability_debits/{fraud_liability_debit}"}),list:u5({method:"GET",fullPath:"/v1/issuing/fraud_liability_debits",methodType:"list"})})});var s5=z((i5)=>{Object.defineProperty(i5,"__esModule",{value:!0});i5.GbBankAccounts=void 0;var d5=H(),k0=d5.StripeResource.method;i5.GbBankAccounts=d5.StripeResource.extend({create:k0({method:"POST",fullPath:"/v2/core/vault/gb_bank_accounts"}),retrieve:k0({method:"GET",fullPath:"/v2/core/vault/gb_bank_accounts/{id}"}),list:k0({method:"GET",fullPath:"/v2/core/vault/gb_bank_accounts",methodType:"list"}),acknowledgeConfirmationOfPayee:k0({method:"POST",fullPath:"/v2/core/vault/gb_bank_accounts/{id}/acknowledge_confirmation_of_payee"}),archive:k0({method:"POST",fullPath:"/v2/core/vault/gb_bank_accounts/{id}/archive"}),initiateConfirmationOfPayee:k0({method:"POST",fullPath:"/v2/core/vault/gb_bank_accounts/{id}/initiate_confirmation_of_payee"})})});var $J=z((t5)=>{Object.defineProperty(t5,"__esModule",{value:!0});t5.Holds=void 0;var r5=H(),o5=r5.StripeResource.method;t5.Holds=r5.StripeResource.extend({retrieve:o5({method:"GET",fullPath:"/v1/reserve/holds/{id}"}),list:o5({method:"GET",fullPath:"/v1/reserve/holds",methodType:"list"})})});var XJ=z((JJ)=>{Object.defineProperty(JJ,"__esModule",{value:!0});JJ.InboundTransfers=void 0;var ZJ=H(),j9=ZJ.StripeResource.method;JJ.InboundTransfers=ZJ.StripeResource.extend({fail:j9({method:"POST",fullPath:"/v1/test_helpers/treasury/inbound_transfers/{id}/fail"}),returnInboundTransfer:j9({method:"POST",fullPath:"/v1/test_helpers/treasury/inbound_transfers/{id}/return"}),succeed:j9({method:"POST",fullPath:"/v1/test_helpers/treasury/inbound_transfers/{id}/succeed"})})});var VJ=z((GJ)=>{Object.defineProperty(GJ,"__esModule",{value:!0});GJ.InboundTransfers=void 0;var QJ=H(),l8=QJ.StripeResource.method;GJ.InboundTransfers=QJ.StripeResource.extend({create:l8({method:"POST",fullPath:"/v1/treasury/inbound_transfers"}),retrieve:l8({method:"GET",fullPath:"/v1/treasury/inbound_transfers/{id}"}),list:l8({method:"GET",fullPath:"/v1/treasury/inbound_transfers",methodType:"list"}),cancel:l8({method:"POST",fullPath:"/v1/treasury/inbound_transfers/{inbound_transfer}/cancel"})})});var zJ=z((LJ)=>{Object.defineProperty(LJ,"__esModule",{value:!0});LJ.InboundTransfers=void 0;var BJ=H(),f9=BJ.StripeResource.method;LJ.InboundTransfers=BJ.StripeResource.extend({create:f9({method:"POST",fullPath:"/v2/money_management/inbound_transfers"}),retrieve:f9({method:"GET",fullPath:"/v2/money_management/inbound_transfers/{id}"}),list:f9({method:"GET",fullPath:"/v2/money_management/inbound_transfers",methodType:"list"})})});var DJ=z((TJ)=>{Object.defineProperty(TJ,"__esModule",{value:!0});TJ.Institutions=void 0;var HJ=H(),KJ=HJ.StripeResource.method;TJ.Institutions=HJ.StripeResource.extend({retrieve:KJ({method:"GET",fullPath:"/v1/financial_connections/institutions/{institution}"}),list:KJ({method:"GET",fullPath:"/v1/financial_connections/institutions",methodType:"list"})})});var CJ=z((qJ)=>{Object.defineProperty(qJ,"__esModule",{value:!0});qJ.Locations=void 0;var OJ=H(),_9=OJ.StripeResource.method;qJ.Locations=OJ.StripeResource.extend({create:_9({method:"POST",fullPath:"/v1/tax/locations"}),retrieve:_9({method:"GET",fullPath:"/v1/tax/locations/{location}"}),list:_9({method:"GET",fullPath:"/v1/tax/locations",methodType:"list"})})});var AJ=z((kJ)=>{Object.defineProperty(kJ,"__esModule",{value:!0});kJ.Locations=void 0;var FJ=H(),e0=FJ.StripeResource.method;kJ.Locations=FJ.StripeResource.extend({create:e0({method:"POST",fullPath:"/v1/terminal/locations"}),retrieve:e0({method:"GET",fullPath:"/v1/terminal/locations/{location}"}),update:e0({method:"POST",fullPath:"/v1/terminal/locations/{location}"}),list:e0({method:"GET",fullPath:"/v1/terminal/locations",methodType:"list"}),del:e0({method:"DELETE",fullPath:"/v1/terminal/locations/{location}"})})});var vJ=z((IJ)=>{Object.defineProperty(IJ,"__esModule",{value:!0});IJ.MeterEventAdjustments=void 0;var NJ=H(),PT=NJ.StripeResource.method;IJ.MeterEventAdjustments=NJ.StripeResource.extend({create:PT({method:"POST",fullPath:"/v1/billing/meter_event_adjustments"})})});var bJ=z((SJ)=>{Object.defineProperty(SJ,"__esModule",{value:!0});SJ.MeterEventAdjustments=void 0;var yJ=H(),vT=yJ.StripeResource.method;SJ.MeterEventAdjustments=yJ.StripeResource.extend({create:vT({method:"POST",fullPath:"/v2/billing/meter_event_adjustments"})})});var gJ=z((fJ)=>{Object.defineProperty(fJ,"__esModule",{value:!0});fJ.MeterEventSession=void 0;var jJ=H(),yT=jJ.StripeResource.method;fJ.MeterEventSession=jJ.StripeResource.extend({create:yT({method:"POST",fullPath:"/v2/billing/meter_event_session"})})});var uJ=z((hJ)=>{Object.defineProperty(hJ,"__esModule",{value:!0});hJ.MeterEventStream=void 0;var MJ=H(),ST=MJ.StripeResource.method;hJ.MeterEventStream=MJ.StripeResource.extend({create:ST({method:"POST",fullPath:"/v2/billing/meter_event_stream",host:"meter-events.stripe.com"})})});var pJ=z((lJ)=>{Object.defineProperty(lJ,"__esModule",{value:!0});lJ.MeterEvents=void 0;var cJ=H(),RT=cJ.StripeResource.method;lJ.MeterEvents=cJ.StripeResource.extend({create:RT({method:"POST",fullPath:"/v1/billing/meter_events"})})});var sJ=z((iJ)=>{Object.defineProperty(iJ,"__esModule",{value:!0});iJ.MeterEvents=void 0;var dJ=H(),bT=dJ.StripeResource.method;iJ.MeterEvents=dJ.StripeResource.extend({create:bT({method:"POST",fullPath:"/v2/billing/meter_events"})})});var eJ=z((rJ)=>{Object.defineProperty(rJ,"__esModule",{value:!0});rJ.MeterUsage=void 0;var oJ=H(),jT=oJ.StripeResource.method;rJ.MeterUsage=oJ.StripeResource.extend({retrieve:jT({method:"GET",fullPath:"/v1/billing/analytics/meter_usage"})})});var YY=z((ZY)=>{Object.defineProperty(ZY,"__esModule",{value:!0});ZY.Meters=void 0;var $Y=H(),W0=$Y.StripeResource.method;ZY.Meters=$Y.StripeResource.extend({create:W0({method:"POST",fullPath:"/v1/billing/meters"}),retrieve:W0({method:"GET",fullPath:"/v1/billing/meters/{id}"}),update:W0({method:"POST",fullPath:"/v1/billing/meters/{id}"}),list:W0({method:"GET",fullPath:"/v1/billing/meters",methodType:"list"}),deactivate:W0({method:"POST",fullPath:"/v1/billing/meters/{id}/deactivate"}),listEventSummaries:W0({method:"GET",fullPath:"/v1/billing/meters/{id}/event_summaries",methodType:"list"}),reactivate:W0({method:"POST",fullPath:"/v1/billing/meters/{id}/reactivate"})})});var WY=z((QY)=>{Object.defineProperty(QY,"__esModule",{value:!0});QY.OnboardingLinks=void 0;var XY=H(),fT=XY.StripeResource.method;QY.OnboardingLinks=XY.StripeResource.extend({create:fT({method:"POST",fullPath:"/v1/terminal/onboarding_links"})})});var UY=z((BY)=>{Object.defineProperty(BY,"__esModule",{value:!0});BY.Orders=void 0;var VY=H(),$8=VY.StripeResource.method;BY.Orders=VY.StripeResource.extend({create:$8({method:"POST",fullPath:"/v1/climate/orders",requestSchema:{kind:"object",fields:{metric_tons:{kind:"decimal_string"}}},responseSchema:{kind:"object",fields:{metric_tons:{kind:"decimal_string"}}}}),retrieve:$8({method:"GET",fullPath:"/v1/climate/orders/{order}",responseSchema:{kind:"object",fields:{metric_tons:{kind:"decimal_string"}}}}),update:$8({method:"POST",fullPath:"/v1/climate/orders/{order}",responseSchema:{kind:"object",fields:{metric_tons:{kind:"decimal_string"}}}}),list:$8({method:"GET",fullPath:"/v1/climate/orders",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{metric_tons:{kind:"decimal_string"}}}}}}}),cancel:$8({method:"POST",fullPath:"/v1/climate/orders/{order}/cancel",responseSchema:{kind:"object",fields:{metric_tons:{kind:"decimal_string"}}}})})});var wY=z((HY)=>{Object.defineProperty(HY,"__esModule",{value:!0});HY.OutboundPaymentQuotes=void 0;var KY=H(),zY=KY.StripeResource.method;HY.OutboundPaymentQuotes=KY.StripeResource.extend({create:zY({method:"POST",fullPath:"/v2/money_management/outbound_payment_quotes"}),retrieve:zY({method:"GET",fullPath:"/v2/money_management/outbound_payment_quotes/{id}"})})});var EY=z((OY)=>{Object.defineProperty(OY,"__esModule",{value:!0});OY.OutboundPayments=void 0;var DY=H(),n8=DY.StripeResource.method;OY.OutboundPayments=DY.StripeResource.extend({update:n8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}"}),fail:n8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}/fail"}),post:n8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}/post"}),returnOutboundPayment:n8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}/return"})})});var xY=z((FY)=>{Object.defineProperty(FY,"__esModule",{value:!0});FY.OutboundPayments=void 0;var CY=H(),p8=CY.StripeResource.method;FY.OutboundPayments=CY.StripeResource.extend({create:p8({method:"POST",fullPath:"/v1/treasury/outbound_payments"}),retrieve:p8({method:"GET",fullPath:"/v1/treasury/outbound_payments/{id}"}),list:p8({method:"GET",fullPath:"/v1/treasury/outbound_payments",methodType:"list"}),cancel:p8({method:"POST",fullPath:"/v1/treasury/outbound_payments/{id}/cancel"})})});var PY=z((NY)=>{Object.defineProperty(NY,"__esModule",{value:!0});NY.OutboundPayments=void 0;var AY=H(),d8=AY.StripeResource.method;NY.OutboundPayments=AY.StripeResource.extend({create:d8({method:"POST",fullPath:"/v2/money_management/outbound_payments"}),retrieve:d8({method:"GET",fullPath:"/v2/money_management/outbound_payments/{id}"}),list:d8({method:"GET",fullPath:"/v2/money_management/outbound_payments",methodType:"list"}),cancel:d8({method:"POST",fullPath:"/v2/money_management/outbound_payments/{id}/cancel"})})});var RY=z((yY)=>{Object.defineProperty(yY,"__esModule",{value:!0});yY.OutboundSetupIntents=void 0;var vY=H(),Z8=vY.StripeResource.method;yY.OutboundSetupIntents=vY.StripeResource.extend({create:Z8({method:"POST",fullPath:"/v2/money_management/outbound_setup_intents"}),retrieve:Z8({method:"GET",fullPath:"/v2/money_management/outbound_setup_intents/{id}"}),update:Z8({method:"POST",fullPath:"/v2/money_management/outbound_setup_intents/{id}"}),list:Z8({method:"GET",fullPath:"/v2/money_management/outbound_setup_intents",methodType:"list"}),cancel:Z8({method:"POST",fullPath:"/v2/money_management/outbound_setup_intents/{id}/cancel"})})});var _Y=z((jY)=>{Object.defineProperty(jY,"__esModule",{value:!0});jY.OutboundTransfers=void 0;var bY=H(),i8=bY.StripeResource.method;jY.OutboundTransfers=bY.StripeResource.extend({update:i8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}"}),fail:i8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/fail"}),post:i8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/post"}),returnOutboundTransfer:i8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/return"})})});var mY=z((MY)=>{Object.defineProperty(MY,"__esModule",{value:!0});MY.OutboundTransfers=void 0;var gY=H(),a8=gY.StripeResource.method;MY.OutboundTransfers=gY.StripeResource.extend({create:a8({method:"POST",fullPath:"/v1/treasury/outbound_transfers"}),retrieve:a8({method:"GET",fullPath:"/v1/treasury/outbound_transfers/{outbound_transfer}"}),list:a8({method:"GET",fullPath:"/v1/treasury/outbound_transfers",methodType:"list"}),cancel:a8({method:"POST",fullPath:"/v1/treasury/outbound_transfers/{outbound_transfer}/cancel"})})});var nY=z((cY)=>{Object.defineProperty(cY,"__esModule",{value:!0});cY.OutboundTransfers=void 0;var uY=H(),s8=uY.StripeResource.method;cY.OutboundTransfers=uY.StripeResource.extend({create:s8({method:"POST",fullPath:"/v2/money_management/outbound_transfers"}),retrieve:s8({method:"GET",fullPath:"/v2/money_management/outbound_transfers/{id}"}),list:s8({method:"GET",fullPath:"/v2/money_management/outbound_transfers",methodType:"list"}),cancel:s8({method:"POST",fullPath:"/v2/money_management/outbound_transfers/{id}/cancel"})})});var aY=z((dY)=>{Object.defineProperty(dY,"__esModule",{value:!0});dY.PaymentEvaluations=void 0;var pY=H(),_T=pY.StripeResource.method;dY.PaymentEvaluations=pY.StripeResource.extend({create:_T({method:"POST",fullPath:"/v1/radar/payment_evaluations"})})});var tY=z((oY)=>{Object.defineProperty(oY,"__esModule",{value:!0});oY.PayoutMethods=void 0;var sY=H(),o8=sY.StripeResource.method;oY.PayoutMethods=sY.StripeResource.extend({retrieve:o8({method:"GET",fullPath:"/v2/money_management/payout_methods/{id}"}),list:o8({method:"GET",fullPath:"/v2/money_management/payout_methods",methodType:"list"}),archive:o8({method:"POST",fullPath:"/v2/money_management/payout_methods/{id}/archive"}),unarchive:o8({method:"POST",fullPath:"/v2/money_management/payout_methods/{id}/unarchive"})})});var J3=z(($3)=>{Object.defineProperty($3,"__esModule",{value:!0});$3.PayoutMethodsBankAccountSpec=void 0;var eY=H(),gT=eY.StripeResource.method;$3.PayoutMethodsBankAccountSpec=eY.StripeResource.extend({retrieve:gT({method:"GET",fullPath:"/v2/money_management/payout_methods_bank_account_spec"})})});var G3=z((X3)=>{Object.defineProperty(X3,"__esModule",{value:!0});X3.PersonalizationDesigns=void 0;var Y3=H(),r8=Y3.StripeResource.method;X3.PersonalizationDesigns=Y3.StripeResource.extend({create:r8({method:"POST",fullPath:"/v1/issuing/personalization_designs"}),retrieve:r8({method:"GET",fullPath:"/v1/issuing/personalization_designs/{personalization_design}"}),update:r8({method:"POST",fullPath:"/v1/issuing/personalization_designs/{personalization_design}"}),list:r8({method:"GET",fullPath:"/v1/issuing/personalization_designs",methodType:"list"})})});var L3=z((V3)=>{Object.defineProperty(V3,"__esModule",{value:!0});V3.PersonalizationDesigns=void 0;var W3=H(),g9=W3.StripeResource.method;V3.PersonalizationDesigns=W3.StripeResource.extend({activate:g9({method:"POST",fullPath:"/v1/test_helpers/issuing/personalization_designs/{personalization_design}/activate"}),deactivate:g9({method:"POST",fullPath:"/v1/test_helpers/issuing/personalization_designs/{personalization_design}/deactivate"}),reject:g9({method:"POST",fullPath:"/v1/test_helpers/issuing/personalization_designs/{personalization_design}/reject"})})});var T3=z((K3)=>{Object.defineProperty(K3,"__esModule",{value:!0});K3.PhysicalBundles=void 0;var z3=H(),U3=z3.StripeResource.method;K3.PhysicalBundles=z3.StripeResource.extend({retrieve:U3({method:"GET",fullPath:"/v1/issuing/physical_bundles/{physical_bundle}"}),list:U3({method:"GET",fullPath:"/v1/issuing/physical_bundles",methodType:"list"})})});var q3=z((D3)=>{Object.defineProperty(D3,"__esModule",{value:!0});D3.Plans=void 0;var w3=H(),MT=w3.StripeResource.method;D3.Plans=w3.StripeResource.extend({retrieve:MT({method:"GET",fullPath:"/v1/reserve/plans/{id}"})})});var x3=z((F3)=>{Object.defineProperty(F3,"__esModule",{value:!0});F3.Products=void 0;var C3=H(),E3=C3.StripeResource.method;F3.Products=C3.StripeResource.extend({retrieve:E3({method:"GET",fullPath:"/v1/climate/products/{product}",responseSchema:{kind:"object",fields:{metric_tons_available:{kind:"decimal_string"}}}}),list:E3({method:"GET",fullPath:"/v1/climate/products",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{metric_tons_available:{kind:"decimal_string"}}}}}}})})});var P3=z((N3)=>{Object.defineProperty(N3,"__esModule",{value:!0});N3.Profiles=void 0;var A3=H(),t8=A3.StripeResource.method;N3.Profiles=A3.StripeResource.extend({create:t8({method:"POST",fullPath:"/v2/billing/profiles"}),retrieve:t8({method:"GET",fullPath:"/v2/billing/profiles/{id}"}),update:t8({method:"POST",fullPath:"/v2/billing/profiles/{id}"}),list:t8({method:"GET",fullPath:"/v2/billing/profiles",methodType:"list"})})});var R3=z((y3)=>{Object.defineProperty(y3,"__esModule",{value:!0});y3.ReaderCollectedData=void 0;var v3=H(),hT=v3.StripeResource.method;y3.ReaderCollectedData=v3.StripeResource.extend({retrieve:hT({method:"GET",fullPath:"/v1/terminal/reader_collected_data/{reader_collected_data}"})})});var _3=z((j3)=>{Object.defineProperty(j3,"__esModule",{value:!0});j3.Readers=void 0;var b3=H(),g=b3.StripeResource.method;j3.Readers=b3.StripeResource.extend({create:g({method:"POST",fullPath:"/v1/terminal/readers"}),retrieve:g({method:"GET",fullPath:"/v1/terminal/readers/{reader}"}),update:g({method:"POST",fullPath:"/v1/terminal/readers/{reader}"}),list:g({method:"GET",fullPath:"/v1/terminal/readers",methodType:"list"}),del:g({method:"DELETE",fullPath:"/v1/terminal/readers/{reader}"}),cancelAction:g({method:"POST",fullPath:"/v1/terminal/readers/{reader}/cancel_action"}),collectInputs:g({method:"POST",fullPath:"/v1/terminal/readers/{reader}/collect_inputs"}),collectPaymentMethod:g({method:"POST",fullPath:"/v1/terminal/readers/{reader}/collect_payment_method"}),confirmPaymentIntent:g({method:"POST",fullPath:"/v1/terminal/readers/{reader}/confirm_payment_intent"}),processPaymentIntent:g({method:"POST",fullPath:"/v1/terminal/readers/{reader}/process_payment_intent"}),processSetupIntent:g({method:"POST",fullPath:"/v1/terminal/readers/{reader}/process_setup_intent"}),refundPayment:g({method:"POST",fullPath:"/v1/terminal/readers/{reader}/refund_payment"}),setReaderDisplay:g({method:"POST",fullPath:"/v1/terminal/readers/{reader}/set_reader_display"})})});var m3=z((M3)=>{Object.defineProperty(M3,"__esModule",{value:!0});M3.Readers=void 0;var g3=H(),M9=g3.StripeResource.method;M3.Readers=g3.StripeResource.extend({presentPaymentMethod:M9({method:"POST",fullPath:"/v1/test_helpers/terminal/readers/{reader}/present_payment_method"}),succeedInputCollection:M9({method:"POST",fullPath:"/v1/test_helpers/terminal/readers/{reader}/succeed_input_collection"}),timeoutInputCollection:M9({method:"POST",fullPath:"/v1/test_helpers/terminal/readers/{reader}/timeout_input_collection"})})});var n3=z((c3)=>{Object.defineProperty(c3,"__esModule",{value:!0});c3.ReceivedCredits=void 0;var u3=H(),mT=u3.StripeResource.method;c3.ReceivedCredits=u3.StripeResource.extend({create:mT({method:"POST",fullPath:"/v1/test_helpers/treasury/received_credits"})})});var s3=z((i3)=>{Object.defineProperty(i3,"__esModule",{value:!0});i3.ReceivedCredits=void 0;var d3=H(),p3=d3.StripeResource.method;i3.ReceivedCredits=d3.StripeResource.extend({retrieve:p3({method:"GET",fullPath:"/v1/treasury/received_credits/{id}"}),list:p3({method:"GET",fullPath:"/v1/treasury/received_credits",methodType:"list"})})});var $X=z((t3)=>{Object.defineProperty(t3,"__esModule",{value:!0});t3.ReceivedCredits=void 0;var r3=H(),o3=r3.StripeResource.method;t3.ReceivedCredits=r3.StripeResource.extend({retrieve:o3({method:"GET",fullPath:"/v2/money_management/received_credits/{id}"}),list:o3({method:"GET",fullPath:"/v2/money_management/received_credits",methodType:"list"})})});var XX=z((JX)=>{Object.defineProperty(JX,"__esModule",{value:!0});JX.ReceivedDebits=void 0;var ZX=H(),uT=ZX.StripeResource.method;JX.ReceivedDebits=ZX.StripeResource.extend({create:uT({method:"POST",fullPath:"/v1/test_helpers/treasury/received_debits"})})});var BX=z((WX)=>{Object.defineProperty(WX,"__esModule",{value:!0});WX.ReceivedDebits=void 0;var GX=H(),QX=GX.StripeResource.method;WX.ReceivedDebits=GX.StripeResource.extend({retrieve:QX({method:"GET",fullPath:"/v1/treasury/received_debits/{id}"}),list:QX({method:"GET",fullPath:"/v1/treasury/received_debits",methodType:"list"})})});var HX=z((zX)=>{Object.defineProperty(zX,"__esModule",{value:!0});zX.ReceivedDebits=void 0;var UX=H(),LX=UX.StripeResource.method;zX.ReceivedDebits=UX.StripeResource.extend({retrieve:LX({method:"GET",fullPath:"/v2/money_management/received_debits/{id}"}),list:LX({method:"GET",fullPath:"/v2/money_management/received_debits",methodType:"list"})})});var OX=z((wX)=>{Object.defineProperty(wX,"__esModule",{value:!0});wX.RedactionJobs=void 0;var TX=H(),t=TX.StripeResource.method;wX.RedactionJobs=TX.StripeResource.extend({create:t({method:"POST",fullPath:"/v1/privacy/redaction_jobs"}),retrieve:t({method:"GET",fullPath:"/v1/privacy/redaction_jobs/{job}"}),update:t({method:"POST",fullPath:"/v1/privacy/redaction_jobs/{job}"}),list:t({method:"GET",fullPath:"/v1/privacy/redaction_jobs",methodType:"list"}),cancel:t({method:"POST",fullPath:"/v1/privacy/redaction_jobs/{job}/cancel"}),listValidationErrors:t({method:"GET",fullPath:"/v1/privacy/redaction_jobs/{job}/validation_errors",methodType:"list"}),run:t({method:"POST",fullPath:"/v1/privacy/redaction_jobs/{job}/run"}),validate:t({method:"POST",fullPath:"/v1/privacy/redaction_jobs/{job}/validate"})})});var FX=z((EX)=>{Object.defineProperty(EX,"__esModule",{value:!0});EX.Refunds=void 0;var qX=H(),cT=qX.StripeResource.method;EX.Refunds=qX.StripeResource.extend({expire:cT({method:"POST",fullPath:"/v1/test_helpers/refunds/{refund}/expire"})})});var NX=z((xX)=>{Object.defineProperty(xX,"__esModule",{value:!0});xX.Registrations=void 0;var kX=H(),e8=kX.StripeResource.method;xX.Registrations=kX.StripeResource.extend({create:e8({method:"POST",fullPath:"/v1/tax/registrations"}),retrieve:e8({method:"GET",fullPath:"/v1/tax/registrations/{id}"}),update:e8({method:"POST",fullPath:"/v1/tax/registrations/{id}"}),list:e8({method:"GET",fullPath:"/v1/tax/registrations",methodType:"list"})})});var SX=z((vX)=>{Object.defineProperty(vX,"__esModule",{value:!0});vX.Releases=void 0;var PX=H(),IX=PX.StripeResource.method;vX.Releases=PX.StripeResource.extend({retrieve:IX({method:"GET",fullPath:"/v1/reserve/releases/{id}"}),list:IX({method:"GET",fullPath:"/v1/reserve/releases",methodType:"list"})})});var fX=z((bX)=>{Object.defineProperty(bX,"__esModule",{value:!0});bX.ReportRuns=void 0;var RX=H(),h9=RX.StripeResource.method;bX.ReportRuns=RX.StripeResource.extend({create:h9({method:"POST",fullPath:"/v1/reporting/report_runs"}),retrieve:h9({method:"GET",fullPath:"/v1/reporting/report_runs/{report_run}"}),list:h9({method:"GET",fullPath:"/v1/reporting/report_runs",methodType:"list"})})});var mX=z((MX)=>{Object.defineProperty(MX,"__esModule",{value:!0});MX.ReportTypes=void 0;var gX=H(),_X=gX.StripeResource.method;MX.ReportTypes=gX.StripeResource.extend({retrieve:_X({method:"GET",fullPath:"/v1/reporting/report_types/{report_type}"}),list:_X({method:"GET",fullPath:"/v1/reporting/report_types",methodType:"list"})})});var nX=z((cX)=>{Object.defineProperty(cX,"__esModule",{value:!0});cX.Requests=void 0;var uX=H(),m9=uX.StripeResource.method;cX.Requests=uX.StripeResource.extend({create:m9({method:"POST",fullPath:"/v1/forwarding/requests"}),retrieve:m9({method:"GET",fullPath:"/v1/forwarding/requests/{id}"}),list:m9({method:"GET",fullPath:"/v1/forwarding/requests",methodType:"list"})})});var sX=z((iX)=>{Object.defineProperty(iX,"__esModule",{value:!0});iX.ScheduledQueryRuns=void 0;var dX=H(),pX=dX.StripeResource.method;iX.ScheduledQueryRuns=dX.StripeResource.extend({retrieve:pX({method:"GET",fullPath:"/v1/sigma/scheduled_query_runs/{scheduled_query_run}"}),list:pX({method:"GET",fullPath:"/v1/sigma/scheduled_query_runs",methodType:"list"})})});var eX=z((rX)=>{Object.defineProperty(rX,"__esModule",{value:!0});rX.Secrets=void 0;var oX=H(),$$=oX.StripeResource.method;rX.Secrets=oX.StripeResource.extend({create:$$({method:"POST",fullPath:"/v1/apps/secrets"}),list:$$({method:"GET",fullPath:"/v1/apps/secrets",methodType:"list"}),deleteWhere:$$({method:"POST",fullPath:"/v1/apps/secrets/delete"}),find:$$({method:"GET",fullPath:"/v1/apps/secrets/find"})})});var YQ=z((ZQ)=>{Object.defineProperty(ZQ,"__esModule",{value:!0});ZQ.Sessions=void 0;var $Q=H(),lT=$Q.StripeResource.method;ZQ.Sessions=$Q.StripeResource.extend({create:lT({method:"POST",fullPath:"/v1/billing_portal/sessions"})})});var WQ=z((QQ)=>{Object.defineProperty(QQ,"__esModule",{value:!0});QQ.Sessions=void 0;var XQ=H(),x0=XQ.StripeResource.method;QQ.Sessions=XQ.StripeResource.extend({create:x0({method:"POST",fullPath:"/v1/checkout/sessions",requestSchema:{kind:"object",fields:{line_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{currency_conversion:{kind:"nullable",inner:{kind:"object",fields:{fx_rate:{kind:"decimal_string"}}}},line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),retrieve:x0({method:"GET",fullPath:"/v1/checkout/sessions/{session}",responseSchema:{kind:"object",fields:{currency_conversion:{kind:"nullable",inner:{kind:"object",fields:{fx_rate:{kind:"decimal_string"}}}},line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),update:x0({method:"POST",fullPath:"/v1/checkout/sessions/{session}",requestSchema:{kind:"object",fields:{line_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{currency_conversion:{kind:"nullable",inner:{kind:"object",fields:{fx_rate:{kind:"decimal_string"}}}},line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),list:x0({method:"GET",fullPath:"/v1/checkout/sessions",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{currency_conversion:{kind:"nullable",inner:{kind:"object",fields:{fx_rate:{kind:"decimal_string"}}}},line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}),expire:x0({method:"POST",fullPath:"/v1/checkout/sessions/{session}/expire",responseSchema:{kind:"object",fields:{currency_conversion:{kind:"nullable",inner:{kind:"object",fields:{fx_rate:{kind:"decimal_string"}}}},line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),listLineItems:x0({method:"GET",fullPath:"/v1/checkout/sessions/{session}/line_items",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}})})});var zQ=z((LQ)=>{Object.defineProperty(LQ,"__esModule",{value:!0});LQ.Sessions=void 0;var BQ=H(),VQ=BQ.StripeResource.method;LQ.Sessions=BQ.StripeResource.extend({create:VQ({method:"POST",fullPath:"/v1/financial_connections/sessions"}),retrieve:VQ({method:"GET",fullPath:"/v1/financial_connections/sessions/{session}"})})});var DQ=z((TQ)=>{Object.defineProperty(TQ,"__esModule",{value:!0});TQ.Settings=void 0;var HQ=H(),KQ=HQ.StripeResource.method;TQ.Settings=HQ.StripeResource.extend({retrieve:KQ({method:"GET",fullPath:"/v1/tax/settings"}),update:KQ({method:"POST",fullPath:"/v1/tax/settings"})})});var FQ=z((EQ)=>{Object.defineProperty(EQ,"__esModule",{value:!0});EQ.Suppliers=void 0;var qQ=H(),OQ=qQ.StripeResource.method;EQ.Suppliers=qQ.StripeResource.extend({retrieve:OQ({method:"GET",fullPath:"/v1/climate/suppliers/{supplier}"}),list:OQ({method:"GET",fullPath:"/v1/climate/suppliers",methodType:"list"})})});var NQ=z((xQ)=>{Object.defineProperty(xQ,"__esModule",{value:!0});xQ.TestClocks=void 0;var kQ=H(),J8=kQ.StripeResource.method;xQ.TestClocks=kQ.StripeResource.extend({create:J8({method:"POST",fullPath:"/v1/test_helpers/test_clocks"}),retrieve:J8({method:"GET",fullPath:"/v1/test_helpers/test_clocks/{test_clock}"}),list:J8({method:"GET",fullPath:"/v1/test_helpers/test_clocks",methodType:"list"}),del:J8({method:"DELETE",fullPath:"/v1/test_helpers/test_clocks/{test_clock}"}),advance:J8({method:"POST",fullPath:"/v1/test_helpers/test_clocks/{test_clock}/advance"})})});var yQ=z((PQ)=>{Object.defineProperty(PQ,"__esModule",{value:!0});PQ.Tokens=void 0;var IQ=H(),u9=IQ.StripeResource.method;PQ.Tokens=IQ.StripeResource.extend({retrieve:u9({method:"GET",fullPath:"/v1/issuing/tokens/{token}"}),update:u9({method:"POST",fullPath:"/v1/issuing/tokens/{token}"}),list:u9({method:"GET",fullPath:"/v1/issuing/tokens",methodType:"list"})})});var fQ=z((bQ)=>{Object.defineProperty(bQ,"__esModule",{value:!0});bQ.TransactionEntries=void 0;var RQ=H(),SQ=RQ.StripeResource.method;bQ.TransactionEntries=RQ.StripeResource.extend({retrieve:SQ({method:"GET",fullPath:"/v1/treasury/transaction_entries/{id}",responseSchema:{kind:"object",fields:{flow_details:{kind:"nullable",inner:{kind:"object",fields:{issuing_authorization:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}),list:SQ({method:"GET",fullPath:"/v1/treasury/transaction_entries",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{flow_details:{kind:"nullable",inner:{kind:"object",fields:{issuing_authorization:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}})})});var mQ=z((MQ)=>{Object.defineProperty(MQ,"__esModule",{value:!0});MQ.TransactionEntries=void 0;var gQ=H(),_Q=gQ.StripeResource.method;MQ.TransactionEntries=gQ.StripeResource.extend({retrieve:_Q({method:"GET",fullPath:"/v2/money_management/transaction_entries/{id}"}),list:_Q({method:"GET",fullPath:"/v2/money_management/transaction_entries",methodType:"list"})})});var pQ=z((lQ)=>{Object.defineProperty(lQ,"__esModule",{value:!0});lQ.Transactions=void 0;var cQ=H(),uQ=cQ.StripeResource.method;lQ.Transactions=cQ.StripeResource.extend({retrieve:uQ({method:"GET",fullPath:"/v1/financial_connections/transactions/{transaction}"}),list:uQ({method:"GET",fullPath:"/v1/financial_connections/transactions",methodType:"list"})})});var sQ=z((iQ)=>{Object.defineProperty(iQ,"__esModule",{value:!0});iQ.Transactions=void 0;var dQ=H(),c9=dQ.StripeResource.method;iQ.Transactions=dQ.StripeResource.extend({retrieve:c9({method:"GET",fullPath:"/v1/issuing/transactions/{transaction}",responseSchema:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}),update:c9({method:"POST",fullPath:"/v1/issuing/transactions/{transaction}",responseSchema:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}),list:c9({method:"GET",fullPath:"/v1/issuing/transactions",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}})})});var eQ=z((rQ)=>{Object.defineProperty(rQ,"__esModule",{value:!0});rQ.Transactions=void 0;var oQ=H(),Z$=oQ.StripeResource.method;rQ.Transactions=oQ.StripeResource.extend({retrieve:Z$({method:"GET",fullPath:"/v1/tax/transactions/{transaction}"}),createFromCalculation:Z$({method:"POST",fullPath:"/v1/tax/transactions/create_from_calculation"}),createReversal:Z$({method:"POST",fullPath:"/v1/tax/transactions/create_reversal"}),listLineItems:Z$({method:"GET",fullPath:"/v1/tax/transactions/{transaction}/line_items",methodType:"list"})})});var YG=z((ZG)=>{Object.defineProperty(ZG,"__esModule",{value:!0});ZG.Transactions=void 0;var $G=H(),l9=$G.StripeResource.method;ZG.Transactions=$G.StripeResource.extend({createForceCapture:l9({method:"POST",fullPath:"/v1/test_helpers/issuing/transactions/create_force_capture",requestSchema:{kind:"object",fields:{purchase_details:{kind:"object",fields:{fleet:{kind:"object",fields:{reported_breakdown:{kind:"object",fields:{fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},non_fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},tax:{kind:"object",fields:{local_amount_decimal:{kind:"decimal_string"},national_amount_decimal:{kind:"decimal_string"}}}}}}},fuel:{kind:"object",fields:{quantity_decimal:{kind:"decimal_string"},unit_cost_decimal:{kind:"decimal_string"}}},receipt:{kind:"array",element:{kind:"object",fields:{quantity:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}),createUnlinkedRefund:l9({method:"POST",fullPath:"/v1/test_helpers/issuing/transactions/create_unlinked_refund",requestSchema:{kind:"object",fields:{purchase_details:{kind:"object",fields:{fleet:{kind:"object",fields:{reported_breakdown:{kind:"object",fields:{fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},non_fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},tax:{kind:"object",fields:{local_amount_decimal:{kind:"decimal_string"},national_amount_decimal:{kind:"decimal_string"}}}}}}},fuel:{kind:"object",fields:{quantity_decimal:{kind:"decimal_string"},unit_cost_decimal:{kind:"decimal_string"}}},receipt:{kind:"array",element:{kind:"object",fields:{quantity:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}),refund:l9({method:"POST",fullPath:"/v1/test_helpers/issuing/transactions/{transaction}/refund",responseSchema:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}})})});var VG=z((GG)=>{Object.defineProperty(GG,"__esModule",{value:!0});GG.Transactions=void 0;var QG=H(),XG=QG.StripeResource.method;GG.Transactions=QG.StripeResource.extend({retrieve:XG({method:"GET",fullPath:"/v1/treasury/transactions/{id}",responseSchema:{kind:"object",fields:{entries:{kind:"nullable",inner:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{flow_details:{kind:"nullable",inner:{kind:"object",fields:{issuing_authorization:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}),list:XG({method:"GET",fullPath:"/v1/treasury/transactions",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{entries:{kind:"nullable",inner:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{flow_details:{kind:"nullable",inner:{kind:"object",fields:{issuing_authorization:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}}}})})});var KG=z((UG)=>{Object.defineProperty(UG,"__esModule",{value:!0});UG.Transactions=void 0;var LG=H(),BG=LG.StripeResource.method;UG.Transactions=LG.StripeResource.extend({retrieve:BG({method:"GET",fullPath:"/v2/money_management/transactions/{id}"}),list:BG({method:"GET",fullPath:"/v2/money_management/transactions",methodType:"list"})})});var DG=z((TG)=>{Object.defineProperty(TG,"__esModule",{value:!0});TG.TrialOffers=void 0;var HG=H(),nT=HG.StripeResource.method;TG.TrialOffers=HG.StripeResource.extend({create:nT({method:"POST",fullPath:"/v1/product_catalog/trial_offers"})})});var CG=z((qG)=>{Object.defineProperty(qG,"__esModule",{value:!0});qG.UsBankAccounts=void 0;var OG=H(),V0=OG.StripeResource.method;qG.UsBankAccounts=OG.StripeResource.extend({create:V0({method:"POST",fullPath:"/v2/core/vault/us_bank_accounts"}),retrieve:V0({method:"GET",fullPath:"/v2/core/vault/us_bank_accounts/{id}"}),update:V0({method:"POST",fullPath:"/v2/core/vault/us_bank_accounts/{id}"}),list:V0({method:"GET",fullPath:"/v2/core/vault/us_bank_accounts",methodType:"list"}),archive:V0({method:"POST",fullPath:"/v2/core/vault/us_bank_accounts/{id}/archive"}),confirmMicrodeposits:V0({method:"POST",fullPath:"/v2/core/vault/us_bank_accounts/{id}/confirm_microdeposits"}),sendMicrodeposits:V0({method:"POST",fullPath:"/v2/core/vault/us_bank_accounts/{id}/send_microdeposits"})})});var AG=z((kG)=>{Object.defineProperty(kG,"__esModule",{value:!0});kG.ValueListItems=void 0;var FG=H(),J$=FG.StripeResource.method;kG.ValueListItems=FG.StripeResource.extend({create:J$({method:"POST",fullPath:"/v1/radar/value_list_items"}),retrieve:J$({method:"GET",fullPath:"/v1/radar/value_list_items/{item}"}),list:J$({method:"GET",fullPath:"/v1/radar/value_list_items",methodType:"list"}),del:J$({method:"DELETE",fullPath:"/v1/radar/value_list_items/{item}"})})});var vG=z((IG)=>{Object.defineProperty(IG,"__esModule",{value:!0});IG.ValueLists=void 0;var NG=H(),Y8=NG.StripeResource.method;IG.ValueLists=NG.StripeResource.extend({create:Y8({method:"POST",fullPath:"/v1/radar/value_lists"}),retrieve:Y8({method:"GET",fullPath:"/v1/radar/value_lists/{value_list}"}),update:Y8({method:"POST",fullPath:"/v1/radar/value_lists/{value_list}"}),list:Y8({method:"GET",fullPath:"/v1/radar/value_lists",methodType:"list"}),del:Y8({method:"DELETE",fullPath:"/v1/radar/value_lists/{value_list}"})})});var jG=z((RG)=>{Object.defineProperty(RG,"__esModule",{value:!0});RG.VerificationReports=void 0;var SG=H(),yG=SG.StripeResource.method;RG.VerificationReports=SG.StripeResource.extend({retrieve:yG({method:"GET",fullPath:"/v1/identity/verification_reports/{report}"}),list:yG({method:"GET",fullPath:"/v1/identity/verification_reports",methodType:"list"})})});var MG=z((_G)=>{Object.defineProperty(_G,"__esModule",{value:!0});_G.VerificationSessions=void 0;var fG=H(),A0=fG.StripeResource.method;_G.VerificationSessions=fG.StripeResource.extend({create:A0({method:"POST",fullPath:"/v1/identity/verification_sessions"}),retrieve:A0({method:"GET",fullPath:"/v1/identity/verification_sessions/{session}"}),update:A0({method:"POST",fullPath:"/v1/identity/verification_sessions/{session}"}),list:A0({method:"GET",fullPath:"/v1/identity/verification_sessions",methodType:"list"}),cancel:A0({method:"POST",fullPath:"/v1/identity/verification_sessions/{session}/cancel"}),redact:A0({method:"POST",fullPath:"/v1/identity/verification_sessions/{session}/redact"})})});var n9=z((mG)=>{Object.defineProperty(mG,"__esModule",{value:!0});mG.Accounts=void 0;var pT=q("crypto"),hG=H(),P=hG.StripeResource.method;mG.Accounts=hG.StripeResource.extend({create:P({method:"POST",fullPath:"/v1/accounts"}),retrieve($,...Z){if(typeof $==="string")return P({method:"GET",fullPath:"/v1/accounts/{id}"}).apply(this,[$,...Z]);else{if($===null||$===void 0)[].shift.apply([$,...Z]);return P({method:"GET",fullPath:"/v1/account"}).apply(this,[$,...Z])}},update:P({method:"POST",fullPath:"/v1/accounts/{account}"}),list:P({method:"GET",fullPath:"/v1/accounts",methodType:"list"}),del:P({method:"DELETE",fullPath:"/v1/accounts/{account}"}),createExternalAccount:P({method:"POST",fullPath:"/v1/accounts/{account}/external_accounts"}),createLoginLink:P({method:"POST",fullPath:"/v1/accounts/{account}/login_links"}),createPerson:P({method:"POST",fullPath:"/v1/accounts/{account}/persons"}),deleteExternalAccount:P({method:"DELETE",fullPath:"/v1/accounts/{account}/external_accounts/{id}"}),deletePerson:P({method:"DELETE",fullPath:"/v1/accounts/{account}/persons/{person}"}),listCapabilities:P({method:"GET",fullPath:"/v1/accounts/{account}/capabilities",methodType:"list"}),listExternalAccounts:P({method:"GET",fullPath:"/v1/accounts/{account}/external_accounts",methodType:"list"}),listPersons:P({method:"GET",fullPath:"/v1/accounts/{account}/persons",methodType:"list"}),reject:P({method:"POST",fullPath:"/v1/accounts/{account}/reject"}),retrieveCurrent:P({method:"GET",fullPath:"/v1/account"}),retrieveCapability:P({method:"GET",fullPath:"/v1/accounts/{account}/capabilities/{capability}"}),retrieveExternalAccount:P({method:"GET",fullPath:"/v1/accounts/{account}/external_accounts/{id}"}),retrievePerson:P({method:"GET",fullPath:"/v1/accounts/{account}/persons/{person}"}),serializeBatchUpdate($,Z={},J={}){let Y=pT.randomUUID(),X=J.apiVersion||this._stripe.getApiField("version"),Q={id:Y,params:Z,stripe_version:X};if(Q.path_params={account:$},J.stripeContext)Q.context=J.stripeContext;return JSON.stringify(Q)},updateCapability:P({method:"POST",fullPath:"/v1/accounts/{account}/capabilities/{capability}"}),updateExternalAccount:P({method:"POST",fullPath:"/v1/accounts/{account}/external_accounts/{id}"}),updatePerson:P({method:"POST",fullPath:"/v1/accounts/{account}/persons/{person}"})})});var pG=z((lG)=>{Object.defineProperty(lG,"__esModule",{value:!0});lG.AccountLinks=void 0;var cG=H(),dT=cG.StripeResource.method;lG.AccountLinks=cG.StripeResource.extend({create:dT({method:"POST",fullPath:"/v1/account_links"})})});var sG=z((iG)=>{Object.defineProperty(iG,"__esModule",{value:!0});iG.AccountNotices=void 0;var dG=H(),p9=dG.StripeResource.method;iG.AccountNotices=dG.StripeResource.extend({retrieve:p9({method:"GET",fullPath:"/v1/account_notices/{account_notice}"}),update:p9({method:"POST",fullPath:"/v1/account_notices/{account_notice}"}),list:p9({method:"GET",fullPath:"/v1/account_notices",methodType:"list"})})});var eG=z((rG)=>{Object.defineProperty(rG,"__esModule",{value:!0});rG.AccountSessions=void 0;var oG=H(),iT=oG.StripeResource.method;rG.AccountSessions=oG.StripeResource.extend({create:iT({method:"POST",fullPath:"/v1/account_sessions"})})});var YW=z((ZW)=>{Object.defineProperty(ZW,"__esModule",{value:!0});ZW.ApplePayDomains=void 0;var $W=H(),Y$=$W.StripeResource.method;ZW.ApplePayDomains=$W.StripeResource.extend({create:Y$({method:"POST",fullPath:"/v1/apple_pay/domains"}),retrieve:Y$({method:"GET",fullPath:"/v1/apple_pay/domains/{domain}"}),list:Y$({method:"GET",fullPath:"/v1/apple_pay/domains",methodType:"list"}),del:Y$({method:"DELETE",fullPath:"/v1/apple_pay/domains/{domain}"})})});var WW=z((QW)=>{Object.defineProperty(QW,"__esModule",{value:!0});QW.ApplicationFees=void 0;var XW=H(),N0=XW.StripeResource.method;QW.ApplicationFees=XW.StripeResource.extend({retrieve:N0({method:"GET",fullPath:"/v1/application_fees/{id}"}),list:N0({method:"GET",fullPath:"/v1/application_fees",methodType:"list"}),createRefund:N0({method:"POST",fullPath:"/v1/application_fees/{id}/refunds"}),listRefunds:N0({method:"GET",fullPath:"/v1/application_fees/{id}/refunds",methodType:"list"}),retrieveRefund:N0({method:"GET",fullPath:"/v1/application_fees/{fee}/refunds/{id}"}),updateRefund:N0({method:"POST",fullPath:"/v1/application_fees/{fee}/refunds/{id}"})})});var UW=z((BW)=>{Object.defineProperty(BW,"__esModule",{value:!0});BW.Balance=void 0;var VW=H(),aT=VW.StripeResource.method;BW.Balance=VW.StripeResource.extend({retrieve:aT({method:"GET",fullPath:"/v1/balance"})})});var wW=z((HW)=>{Object.defineProperty(HW,"__esModule",{value:!0});HW.BalanceSettings=void 0;var KW=H(),zW=KW.StripeResource.method;HW.BalanceSettings=KW.StripeResource.extend({retrieve:zW({method:"GET",fullPath:"/v1/balance_settings"}),update:zW({method:"POST",fullPath:"/v1/balance_settings"})})});var CW=z((qW)=>{Object.defineProperty(qW,"__esModule",{value:!0});qW.BalanceTransactions=void 0;var OW=H(),DW=OW.StripeResource.method;qW.BalanceTransactions=OW.StripeResource.extend({retrieve:DW({method:"GET",fullPath:"/v1/balance_transactions/{id}"}),list:DW({method:"GET",fullPath:"/v1/balance_transactions",methodType:"list"})})});var AW=z((kW)=>{Object.defineProperty(kW,"__esModule",{value:!0});kW.Charges=void 0;var FW=H(),I0=FW.StripeResource.method;kW.Charges=FW.StripeResource.extend({create:I0({method:"POST",fullPath:"/v1/charges"}),retrieve:I0({method:"GET",fullPath:"/v1/charges/{charge}"}),update:I0({method:"POST",fullPath:"/v1/charges/{charge}"}),list:I0({method:"GET",fullPath:"/v1/charges",methodType:"list"}),capture:I0({method:"POST",fullPath:"/v1/charges/{charge}/capture"}),search:I0({method:"GET",fullPath:"/v1/charges/search",methodType:"search"})})});var vW=z((IW)=>{Object.defineProperty(IW,"__esModule",{value:!0});IW.ConfirmationTokens=void 0;var NW=H(),sT=NW.StripeResource.method;IW.ConfirmationTokens=NW.StripeResource.extend({retrieve:sT({method:"GET",fullPath:"/v1/confirmation_tokens/{confirmation_token}"})})});var jW=z((RW)=>{Object.defineProperty(RW,"__esModule",{value:!0});RW.CountrySpecs=void 0;var SW=H(),yW=SW.StripeResource.method;RW.CountrySpecs=SW.StripeResource.extend({retrieve:yW({method:"GET",fullPath:"/v1/country_specs/{country}"}),list:yW({method:"GET",fullPath:"/v1/country_specs",methodType:"list"})})});var MW=z((_W)=>{Object.defineProperty(_W,"__esModule",{value:!0});_W.Coupons=void 0;var fW=H(),X8=fW.StripeResource.method;_W.Coupons=fW.StripeResource.extend({create:X8({method:"POST",fullPath:"/v1/coupons"}),retrieve:X8({method:"GET",fullPath:"/v1/coupons/{coupon}"}),update:X8({method:"POST",fullPath:"/v1/coupons/{coupon}"}),list:X8({method:"GET",fullPath:"/v1/coupons",methodType:"list"}),del:X8({method:"DELETE",fullPath:"/v1/coupons/{coupon}"})})});var cW=z((mW)=>{Object.defineProperty(mW,"__esModule",{value:!0});mW.CreditNotes=void 0;var oT=q("crypto"),hW=H(),e=hW.StripeResource.method;mW.CreditNotes=hW.StripeResource.extend({create:e({method:"POST",fullPath:"/v1/credit_notes",requestSchema:{kind:"object",fields:{lines:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),retrieve:e({method:"GET",fullPath:"/v1/credit_notes/{id}",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),update:e({method:"POST",fullPath:"/v1/credit_notes/{id}",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),list:e({method:"GET",fullPath:"/v1/credit_notes",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),listLineItems:e({method:"GET",fullPath:"/v1/credit_notes/{credit_note}/lines",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),listPreviewLineItems:e({method:"GET",fullPath:"/v1/credit_notes/preview/lines",methodType:"list",requestSchema:{kind:"object",fields:{lines:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),preview:e({method:"GET",fullPath:"/v1/credit_notes/preview",requestSchema:{kind:"object",fields:{lines:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),serializeBatchCreate($={},Z={}){let J=oT.randomUUID(),Y=Z.apiVersion||this._stripe.getApiField("version"),X={id:J,params:$,stripe_version:Y};if(Z.stripeContext)X.context=Z.stripeContext;return JSON.stringify(X)},voidCreditNote:e({method:"POST",fullPath:"/v1/credit_notes/{id}/void",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}})})});var dW=z((nW)=>{Object.defineProperty(nW,"__esModule",{value:!0});nW.CustomerSessions=void 0;var lW=H(),rT=lW.StripeResource.method;nW.CustomerSessions=lW.StripeResource.extend({create:rT({method:"POST",fullPath:"/v1/customer_sessions"})})});var oW=z((aW)=>{Object.defineProperty(aW,"__esModule",{value:!0});aW.Customers=void 0;var tT=q("crypto"),iW=H(),N=iW.StripeResource.method;aW.Customers=iW.StripeResource.extend({create:N({method:"POST",fullPath:"/v1/customers",responseSchema:{kind:"object",fields:{subscriptions:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}),retrieve:N({method:"GET",fullPath:"/v1/customers/{customer}"}),update:N({method:"POST",fullPath:"/v1/customers/{customer}",responseSchema:{kind:"object",fields:{subscriptions:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}),list:N({method:"GET",fullPath:"/v1/customers",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{subscriptions:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}),del:N({method:"DELETE",fullPath:"/v1/customers/{customer}"}),createBalanceTransaction:N({method:"POST",fullPath:"/v1/customers/{customer}/balance_transactions"}),createFundingInstructions:N({method:"POST",fullPath:"/v1/customers/{customer}/funding_instructions"}),createSource:N({method:"POST",fullPath:"/v1/customers/{customer}/sources"}),createTaxId:N({method:"POST",fullPath:"/v1/customers/{customer}/tax_ids"}),deleteDiscount:N({method:"DELETE",fullPath:"/v1/customers/{customer}/discount"}),deleteSource:N({method:"DELETE",fullPath:"/v1/customers/{customer}/sources/{id}"}),deleteTaxId:N({method:"DELETE",fullPath:"/v1/customers/{customer}/tax_ids/{id}"}),listBalanceTransactions:N({method:"GET",fullPath:"/v1/customers/{customer}/balance_transactions",methodType:"list"}),listCashBalanceTransactions:N({method:"GET",fullPath:"/v1/customers/{customer}/cash_balance_transactions",methodType:"list"}),listPaymentMethods:N({method:"GET",fullPath:"/v1/customers/{customer}/payment_methods",methodType:"list"}),listSources:N({method:"GET",fullPath:"/v1/customers/{customer}/sources",methodType:"list"}),listTaxIds:N({method:"GET",fullPath:"/v1/customers/{customer}/tax_ids",methodType:"list"}),retrieveBalanceTransaction:N({method:"GET",fullPath:"/v1/customers/{customer}/balance_transactions/{transaction}"}),retrieveCashBalance:N({method:"GET",fullPath:"/v1/customers/{customer}/cash_balance"}),retrieveCashBalanceTransaction:N({method:"GET",fullPath:"/v1/customers/{customer}/cash_balance_transactions/{transaction}"}),retrievePaymentMethod:N({method:"GET",fullPath:"/v1/customers/{customer}/payment_methods/{payment_method}"}),retrieveSource:N({method:"GET",fullPath:"/v1/customers/{customer}/sources/{id}"}),retrieveTaxId:N({method:"GET",fullPath:"/v1/customers/{customer}/tax_ids/{id}"}),search:N({method:"GET",fullPath:"/v1/customers/search",methodType:"search",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{subscriptions:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}),serializeBatchUpdate($,Z={},J={}){let Y=tT.randomUUID(),X=J.apiVersion||this._stripe.getApiField("version"),Q={id:Y,params:Z,stripe_version:X};if(Q.path_params={customer:$},J.stripeContext)Q.context=J.stripeContext;return JSON.stringify(Q)},updateBalanceTransaction:N({method:"POST",fullPath:"/v1/customers/{customer}/balance_transactions/{transaction}"}),updateCashBalance:N({method:"POST",fullPath:"/v1/customers/{customer}/cash_balance"}),updateSource:N({method:"POST",fullPath:"/v1/customers/{customer}/sources/{id}"}),verifySource:N({method:"POST",fullPath:"/v1/customers/{customer}/sources/{id}/verify"})})});var $V=z((tW)=>{Object.defineProperty(tW,"__esModule",{value:!0});tW.Disputes=void 0;var rW=H(),X$=rW.StripeResource.method;tW.Disputes=rW.StripeResource.extend({retrieve:X$({method:"GET",fullPath:"/v1/disputes/{dispute}"}),update:X$({method:"POST",fullPath:"/v1/disputes/{dispute}"}),list:X$({method:"GET",fullPath:"/v1/disputes",methodType:"list"}),close:X$({method:"POST",fullPath:"/v1/disputes/{dispute}/close"})})});var QV=z((YV)=>{Object.defineProperty(YV,"__esModule",{value:!0});YV.EphemeralKeys=void 0;var JV=H(),ZV=JV.StripeResource.method;YV.EphemeralKeys=JV.StripeResource.extend({create:ZV({method:"POST",fullPath:"/v1/ephemeral_keys",validator:($,Z)=>{if(!Z.headers||!Z.headers["Stripe-Version"])throw Error("Passing apiVersion in a separate options hash is required to create an ephemeral key. See https://stripe.com/docs/api/versioning?lang=node")}}),del:ZV({method:"DELETE",fullPath:"/v1/ephemeral_keys/{key}"})})});var LV=z((VV)=>{Object.defineProperty(VV,"__esModule",{value:!0});VV.Events=void 0;var WV=H(),GV=WV.StripeResource.method;VV.Events=WV.StripeResource.extend({retrieve:GV({method:"GET",fullPath:"/v1/events/{id}"}),list:GV({method:"GET",fullPath:"/v1/events",methodType:"list"})})});var TV=z((KV)=>{Object.defineProperty(KV,"__esModule",{value:!0});KV.ExchangeRates=void 0;var zV=H(),UV=zV.StripeResource.method;KV.ExchangeRates=zV.StripeResource.extend({retrieve:UV({method:"GET",fullPath:"/v1/exchange_rates/{rate_id}"}),list:UV({method:"GET",fullPath:"/v1/exchange_rates",methodType:"list"})})});var qV=z((DV)=>{Object.defineProperty(DV,"__esModule",{value:!0});DV.ExternalAccounts=void 0;var wV=H(),Q8=wV.StripeResource.method;DV.ExternalAccounts=wV.StripeResource.extend({create:Q8({method:"POST",fullPath:"/v1/external_accounts"}),retrieve:Q8({method:"GET",fullPath:"/v1/external_accounts/{id}"}),update:Q8({method:"POST",fullPath:"/v1/external_accounts/{id}"}),list:Q8({method:"GET",fullPath:"/v1/external_accounts",methodType:"list"}),del:Q8({method:"DELETE",fullPath:"/v1/external_accounts/{id}"})})});var kV=z((CV)=>{Object.defineProperty(CV,"__esModule",{value:!0});CV.FileLinks=void 0;var EV=H(),Q$=EV.StripeResource.method;CV.FileLinks=EV.StripeResource.extend({create:Q$({method:"POST",fullPath:"/v1/file_links"}),retrieve:Q$({method:"GET",fullPath:"/v1/file_links/{link}"}),update:Q$({method:"POST",fullPath:"/v1/file_links/{link}"}),list:Q$({method:"GET",fullPath:"/v1/file_links",methodType:"list"})})});var IV=z((AV)=>{Object.defineProperty(AV,"__esModule",{value:!0});AV.multipartRequestDataProcessor=void 0;var xV=l(),eT=($,Z,J)=>{let Y=(Math.round(Math.random()*10000000000000000)+Math.round(Math.random()*10000000000000000)).toString();J["Content-Type"]=`multipart/form-data; boundary=${Y}`;let X=new TextEncoder,Q=new Uint8Array(0),G=X.encode(`\r
12
- `);function W(V){let U=Q,K=V instanceof Uint8Array?V:new Uint8Array(X.encode(V));Q=new Uint8Array(U.length+K.length+2),Q.set(U),Q.set(K,U.length),Q.set(G,Q.length-2)}function L(V){return`"${V.replace(/"|"/g,"%22").replace(/\r\n|\r|\n/g," ")}"`}let B=(0,xV.flattenAndStringify)(Z);for(let V in B){if(!Object.prototype.hasOwnProperty.call(B,V))continue;let U=B[V];if(W(`--${Y}`),Object.prototype.hasOwnProperty.call(U,"data")){let K=U;W(`Content-Disposition: form-data; name=${L(V)}; filename=${L(K.name||"blob")}`),W(`Content-Type: ${K.type||"application/octet-stream"}`),W(""),W(K.data)}else W(`Content-Disposition: form-data; name=${L(V)}`),W(""),W(U)}return W(`--${Y}--`),Q};function $w($,Z,J,Y){if(Z=Z||{},$!=="POST")return Y(null,(0,xV.queryStringifyRequestData)(Z));this._stripe._platformFunctions.tryBufferData(Z).then((X)=>{let Q=eT($,X,J);return Y(null,Q)}).catch((X)=>Y(X,null))}AV.multipartRequestDataProcessor=$w});var SV=z((vV)=>{Object.defineProperty(vV,"__esModule",{value:!0});vV.Files=void 0;var Zw=IV(),PV=H(),d9=PV.StripeResource.method;vV.Files=PV.StripeResource.extend({create:d9({method:"POST",fullPath:"/v1/files",headers:{"Content-Type":"multipart/form-data"},host:"files.stripe.com"}),retrieve:d9({method:"GET",fullPath:"/v1/files/{file}"}),list:d9({method:"GET",fullPath:"/v1/files",methodType:"list"}),requestDataProcessor:Zw.multipartRequestDataProcessor})});var fV=z((bV)=>{Object.defineProperty(bV,"__esModule",{value:!0});bV.FxQuotes=void 0;var RV=H(),i9=RV.StripeResource.method;bV.FxQuotes=RV.StripeResource.extend({create:i9({method:"POST",fullPath:"/v1/fx_quotes"}),retrieve:i9({method:"GET",fullPath:"/v1/fx_quotes/{id}"}),list:i9({method:"GET",fullPath:"/v1/fx_quotes",methodType:"list"})})});var hV=z((gV)=>{Object.defineProperty(gV,"__esModule",{value:!0});gV.InvoiceItems=void 0;var _V=H(),G8=_V.StripeResource.method;gV.InvoiceItems=_V.StripeResource.extend({create:G8({method:"POST",fullPath:"/v1/invoiceitems",requestSchema:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}},quantity_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}},responseSchema:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"decimal_string"}}}}),retrieve:G8({method:"GET",fullPath:"/v1/invoiceitems/{invoiceitem}",responseSchema:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"decimal_string"}}}}),update:G8({method:"POST",fullPath:"/v1/invoiceitems/{invoiceitem}",requestSchema:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}},quantity_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}},responseSchema:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"decimal_string"}}}}),list:G8({method:"GET",fullPath:"/v1/invoiceitems",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"decimal_string"}}}}}}}),del:G8({method:"DELETE",fullPath:"/v1/invoiceitems/{invoiceitem}"})})});var nV=z((cV)=>{Object.defineProperty(cV,"__esModule",{value:!0});cV.InvoicePayments=void 0;var uV=H(),mV=uV.StripeResource.method;cV.InvoicePayments=uV.StripeResource.extend({retrieve:mV({method:"GET",fullPath:"/v1/invoice_payments/{invoice_payment}"}),list:mV({method:"GET",fullPath:"/v1/invoice_payments",methodType:"list"})})});var aV=z((dV)=>{Object.defineProperty(dV,"__esModule",{value:!0});dV.InvoiceRenderingTemplates=void 0;var pV=H(),G$=pV.StripeResource.method;dV.InvoiceRenderingTemplates=pV.StripeResource.extend({retrieve:G$({method:"GET",fullPath:"/v1/invoice_rendering_templates/{template}"}),list:G$({method:"GET",fullPath:"/v1/invoice_rendering_templates",methodType:"list"}),archive:G$({method:"POST",fullPath:"/v1/invoice_rendering_templates/{template}/archive"}),unarchive:G$({method:"POST",fullPath:"/v1/invoice_rendering_templates/{template}/unarchive"})})});var eV=z((rV)=>{Object.defineProperty(rV,"__esModule",{value:!0});rV.Invoices=void 0;var sV=q("crypto"),oV=H(),y=oV.StripeResource.method;rV.Invoices=oV.StripeResource.extend({create:y({method:"POST",fullPath:"/v1/invoices",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),retrieve:y({method:"GET",fullPath:"/v1/invoices/{invoice}",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),update:y({method:"POST",fullPath:"/v1/invoices/{invoice}",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),list:y({method:"GET",fullPath:"/v1/invoices",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),del:y({method:"DELETE",fullPath:"/v1/invoices/{invoice}"}),addLines:y({method:"POST",fullPath:"/v1/invoices/{invoice}/add_lines",requestSchema:{kind:"object",fields:{lines:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}},quantity_decimal:{kind:"decimal_string"}}}}}},responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),attachPayment:y({method:"POST",fullPath:"/v1/invoices/{invoice}/attach_payment",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),createPreview:y({method:"POST",fullPath:"/v1/invoices/create_preview",requestSchema:{kind:"object",fields:{invoice_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}},quantity_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}}},schedule_details:{kind:"object",fields:{phases:{kind:"array",element:{kind:"object",fields:{add_invoice_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}}}}},subscription_details:{kind:"object",fields:{items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}}}},responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),detachPayment:y({method:"POST",fullPath:"/v1/invoices/{invoice}/detach_payment",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),finalizeInvoice:y({method:"POST",fullPath:"/v1/invoices/{invoice}/finalize",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),listLineItems:y({method:"GET",fullPath:"/v1/invoices/{invoice}/lines",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),markUncollectible:y({method:"POST",fullPath:"/v1/invoices/{invoice}/mark_uncollectible",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),pay:y({method:"POST",fullPath:"/v1/invoices/{invoice}/pay",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),removeLines:y({method:"POST",fullPath:"/v1/invoices/{invoice}/remove_lines",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),search:y({method:"GET",fullPath:"/v1/invoices/search",methodType:"search",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),sendInvoice:y({method:"POST",fullPath:"/v1/invoices/{invoice}/send",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),serializeBatchPay($,Z={},J={}){let Y=sV.randomUUID(),X=J.apiVersion||this._stripe.getApiField("version"),Q={id:Y,params:Z,stripe_version:X};if(Q.path_params={invoice:$},J.stripeContext)Q.context=J.stripeContext;return JSON.stringify(Q)},serializeBatchUpdate($,Z={},J={}){let Y=sV.randomUUID(),X=J.apiVersion||this._stripe.getApiField("version"),Q={id:Y,params:Z,stripe_version:X};if(Q.path_params={invoice:$},J.stripeContext)Q.context=J.stripeContext;return JSON.stringify(Q)},updateLines:y({method:"POST",fullPath:"/v1/invoices/{invoice}/update_lines",requestSchema:{kind:"object",fields:{lines:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}},quantity_decimal:{kind:"decimal_string"}}}}}},responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),updateLineItem:y({method:"POST",fullPath:"/v1/invoices/{invoice}/lines/{line_item_id}",requestSchema:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}},quantity_decimal:{kind:"decimal_string"}}},responseSchema:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}),voidInvoice:y({method:"POST",fullPath:"/v1/invoices/{invoice}/void",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}})})});var XB=z((JB)=>{Object.defineProperty(JB,"__esModule",{value:!0});JB.Mandates=void 0;var ZB=H(),$B=ZB.StripeResource.method;JB.Mandates=ZB.StripeResource.extend({retrieve:$B({method:"GET",fullPath:"/v1/mandates/{mandate}"}),list:$B({method:"GET",fullPath:"/v1/mandates",methodType:"list"})})});var VB=z((GB)=>{Object.defineProperty(GB,"__esModule",{value:!0});GB.Margins=void 0;var QB=H(),W$=QB.StripeResource.method;GB.Margins=QB.StripeResource.extend({create:W$({method:"POST",fullPath:"/v1/billing/margins"}),retrieve:W$({method:"GET",fullPath:"/v1/billing/margins/{margin}"}),update:W$({method:"POST",fullPath:"/v1/billing/margins/{margin}"}),list:W$({method:"GET",fullPath:"/v1/billing/margins",methodType:"list"})})});var KB=z((UB)=>{Object.defineProperty(UB,"__esModule",{value:!0});UB.OAuth=void 0;var LB=H(),Jw=l(),BB=LB.StripeResource.method,a9="connect.stripe.com";UB.OAuth=LB.StripeResource.extend({basePath:"/",authorizeUrl($,Z){$=$||{},Z=Z||{};let J="oauth/authorize";if(Z.express)J=`express/${J}`;if(!$.response_type)$.response_type="code";if(!$.client_id)$.client_id=this._stripe.getClientId();if(!$.scope)$.scope="read_write";return`https://${a9}/${J}?${(0,Jw.queryStringifyRequestData)($)}`},token:BB({method:"POST",path:"oauth/token",host:a9}),deauthorize($,...Z){if(!$.client_id)$.client_id=this._stripe.getClientId();return BB({method:"POST",path:"oauth/deauthorize",host:a9}).apply(this,[$,...Z])}})});var DB=z((TB)=>{Object.defineProperty(TB,"__esModule",{value:!0});TB.Orders=void 0;var HB=H(),W8=HB.StripeResource.method;TB.Orders=HB.StripeResource.extend({create:W8({method:"POST",fullPath:"/v1/orders",requestSchema:{kind:"object",fields:{line_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),retrieve:W8({method:"GET",fullPath:"/v1/orders/{id}",responseSchema:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),update:W8({method:"POST",fullPath:"/v1/orders/{id}",requestSchema:{kind:"object",fields:{line_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),list:W8({method:"GET",fullPath:"/v1/orders",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}),submit:W8({method:"POST",fullPath:"/v1/orders/{id}/submit",responseSchema:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}})})});var FB=z((EB)=>{Object.defineProperty(EB,"__esModule",{value:!0});EB.PaymentAttemptRecords=void 0;var qB=H(),OB=qB.StripeResource.method;EB.PaymentAttemptRecords=qB.StripeResource.extend({retrieve:OB({method:"GET",fullPath:"/v1/payment_attempt_records/{id}"}),list:OB({method:"GET",fullPath:"/v1/payment_attempt_records",methodType:"list"})})});var NB=z((xB)=>{Object.defineProperty(xB,"__esModule",{value:!0});xB.PaymentIntents=void 0;var kB=H(),_=kB.StripeResource.method;xB.PaymentIntents=kB.StripeResource.extend({create:_({method:"POST",fullPath:"/v1/payment_intents"}),retrieve:_({method:"GET",fullPath:"/v1/payment_intents/{intent}"}),update:_({method:"POST",fullPath:"/v1/payment_intents/{intent}"}),list:_({method:"GET",fullPath:"/v1/payment_intents",methodType:"list"}),applyCustomerBalance:_({method:"POST",fullPath:"/v1/payment_intents/{intent}/apply_customer_balance"}),cancel:_({method:"POST",fullPath:"/v1/payment_intents/{intent}/cancel"}),capture:_({method:"POST",fullPath:"/v1/payment_intents/{intent}/capture"}),confirm:_({method:"POST",fullPath:"/v1/payment_intents/{intent}/confirm"}),decrementAuthorization:_({method:"POST",fullPath:"/v1/payment_intents/{intent}/decrement_authorization"}),incrementAuthorization:_({method:"POST",fullPath:"/v1/payment_intents/{intent}/increment_authorization"}),listAmountDetailsLineItems:_({method:"GET",fullPath:"/v1/payment_intents/{intent}/amount_details_line_items",methodType:"list"}),search:_({method:"GET",fullPath:"/v1/payment_intents/search",methodType:"search"}),triggerAction:_({method:"POST",fullPath:"/v1/test/payment_intents/{intent}/trigger_action"}),verifyMicrodeposits:_({method:"POST",fullPath:"/v1/payment_intents/{intent}/verify_microdeposits"})})});var yB=z((PB)=>{Object.defineProperty(PB,"__esModule",{value:!0});PB.PaymentLinks=void 0;var IB=H(),V8=IB.StripeResource.method;PB.PaymentLinks=IB.StripeResource.extend({create:V8({method:"POST",fullPath:"/v1/payment_links",requestSchema:{kind:"object",fields:{line_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),retrieve:V8({method:"GET",fullPath:"/v1/payment_links/{payment_link}",responseSchema:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),update:V8({method:"POST",fullPath:"/v1/payment_links/{payment_link}",responseSchema:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),list:V8({method:"GET",fullPath:"/v1/payment_links",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}),listLineItems:V8({method:"GET",fullPath:"/v1/payment_links/{payment_link}/line_items",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}})})});var jB=z((RB)=>{Object.defineProperty(RB,"__esModule",{value:!0});RB.PaymentMethodConfigurations=void 0;var SB=H(),V$=SB.StripeResource.method;RB.PaymentMethodConfigurations=SB.StripeResource.extend({create:V$({method:"POST",fullPath:"/v1/payment_method_configurations"}),retrieve:V$({method:"GET",fullPath:"/v1/payment_method_configurations/{configuration}"}),update:V$({method:"POST",fullPath:"/v1/payment_method_configurations/{configuration}"}),list:V$({method:"GET",fullPath:"/v1/payment_method_configurations",methodType:"list"})})});var MB=z((_B)=>{Object.defineProperty(_B,"__esModule",{value:!0});_B.PaymentMethodDomains=void 0;var fB=H(),B8=fB.StripeResource.method;_B.PaymentMethodDomains=fB.StripeResource.extend({create:B8({method:"POST",fullPath:"/v1/payment_method_domains"}),retrieve:B8({method:"GET",fullPath:"/v1/payment_method_domains/{payment_method_domain}"}),update:B8({method:"POST",fullPath:"/v1/payment_method_domains/{payment_method_domain}"}),list:B8({method:"GET",fullPath:"/v1/payment_method_domains",methodType:"list"}),validate:B8({method:"POST",fullPath:"/v1/payment_method_domains/{payment_method_domain}/validate"})})});var cB=z((mB)=>{Object.defineProperty(mB,"__esModule",{value:!0});mB.PaymentMethods=void 0;var hB=H(),P0=hB.StripeResource.method;mB.PaymentMethods=hB.StripeResource.extend({create:P0({method:"POST",fullPath:"/v1/payment_methods"}),retrieve:P0({method:"GET",fullPath:"/v1/payment_methods/{payment_method}"}),update:P0({method:"POST",fullPath:"/v1/payment_methods/{payment_method}"}),list:P0({method:"GET",fullPath:"/v1/payment_methods",methodType:"list"}),attach:P0({method:"POST",fullPath:"/v1/payment_methods/{payment_method}/attach"}),detach:P0({method:"POST",fullPath:"/v1/payment_methods/{payment_method}/detach"})})});var dB=z((nB)=>{Object.defineProperty(nB,"__esModule",{value:!0});nB.PaymentRecords=void 0;var lB=H(),$0=lB.StripeResource.method;nB.PaymentRecords=lB.StripeResource.extend({retrieve:$0({method:"GET",fullPath:"/v1/payment_records/{id}"}),reportPayment:$0({method:"POST",fullPath:"/v1/payment_records/report_payment"}),reportPaymentAttempt:$0({method:"POST",fullPath:"/v1/payment_records/{id}/report_payment_attempt"}),reportPaymentAttemptCanceled:$0({method:"POST",fullPath:"/v1/payment_records/{id}/report_payment_attempt_canceled"}),reportPaymentAttemptFailed:$0({method:"POST",fullPath:"/v1/payment_records/{id}/report_payment_attempt_failed"}),reportPaymentAttemptGuaranteed:$0({method:"POST",fullPath:"/v1/payment_records/{id}/report_payment_attempt_guaranteed"}),reportPaymentAttemptInformational:$0({method:"POST",fullPath:"/v1/payment_records/{id}/report_payment_attempt_informational"}),reportRefund:$0({method:"POST",fullPath:"/v1/payment_records/{id}/report_refund"})})});var oB=z((aB)=>{Object.defineProperty(aB,"__esModule",{value:!0});aB.Payouts=void 0;var iB=H(),v0=iB.StripeResource.method;aB.Payouts=iB.StripeResource.extend({create:v0({method:"POST",fullPath:"/v1/payouts"}),retrieve:v0({method:"GET",fullPath:"/v1/payouts/{payout}"}),update:v0({method:"POST",fullPath:"/v1/payouts/{payout}"}),list:v0({method:"GET",fullPath:"/v1/payouts",methodType:"list"}),cancel:v0({method:"POST",fullPath:"/v1/payouts/{payout}/cancel"}),reverse:v0({method:"POST",fullPath:"/v1/payouts/{payout}/reverse"})})});var $L=z((tB)=>{Object.defineProperty(tB,"__esModule",{value:!0});tB.Plans=void 0;var rB=H(),L8=rB.StripeResource.method;tB.Plans=rB.StripeResource.extend({create:L8({method:"POST",fullPath:"/v1/plans",requestSchema:{kind:"object",fields:{amount_decimal:{kind:"decimal_string"},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}}}}},responseSchema:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),retrieve:L8({method:"GET",fullPath:"/v1/plans/{plan}",responseSchema:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),update:L8({method:"POST",fullPath:"/v1/plans/{plan}",responseSchema:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),list:L8({method:"GET",fullPath:"/v1/plans",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}),del:L8({method:"DELETE",fullPath:"/v1/plans/{plan}"})})});var XL=z((JL)=>{Object.defineProperty(JL,"__esModule",{value:!0});JL.Prices=void 0;var ZL=H(),U8=ZL.StripeResource.method;JL.Prices=ZL.StripeResource.extend({create:U8({method:"POST",fullPath:"/v1/prices",requestSchema:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}}},unit_amount_decimal:{kind:"decimal_string"}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}}},unit_amount_decimal:{kind:"decimal_string"}}},responseSchema:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}),retrieve:U8({method:"GET",fullPath:"/v1/prices/{price}",responseSchema:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}),update:U8({method:"POST",fullPath:"/v1/prices/{price}",responseSchema:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}),list:U8({method:"GET",fullPath:"/v1/prices",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),search:U8({method:"GET",fullPath:"/v1/prices/search",methodType:"search",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}})})});var VL=z((GL)=>{Object.defineProperty(GL,"__esModule",{value:!0});GL.Products=void 0;var QL=H(),n=QL.StripeResource.method;GL.Products=QL.StripeResource.extend({create:n({method:"POST",fullPath:"/v1/products",requestSchema:{kind:"object",fields:{default_price_data:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}}},unit_amount_decimal:{kind:"decimal_string"}}}},unit_amount_decimal:{kind:"decimal_string"}}}}}}),retrieve:n({method:"GET",fullPath:"/v1/products/{id}"}),update:n({method:"POST",fullPath:"/v1/products/{id}"}),list:n({method:"GET",fullPath:"/v1/products",methodType:"list"}),del:n({method:"DELETE",fullPath:"/v1/products/{id}"}),createFeature:n({method:"POST",fullPath:"/v1/products/{product}/features"}),deleteFeature:n({method:"DELETE",fullPath:"/v1/products/{product}/features/{id}"}),listFeatures:n({method:"GET",fullPath:"/v1/products/{product}/features",methodType:"list"}),retrieveFeature:n({method:"GET",fullPath:"/v1/products/{product}/features/{id}"}),search:n({method:"GET",fullPath:"/v1/products/search",methodType:"search"})})});var KL=z((UL)=>{Object.defineProperty(UL,"__esModule",{value:!0});UL.PromotionCodes=void 0;var BL=q("crypto"),LL=H(),B$=LL.StripeResource.method;UL.PromotionCodes=LL.StripeResource.extend({create:B$({method:"POST",fullPath:"/v1/promotion_codes"}),retrieve:B$({method:"GET",fullPath:"/v1/promotion_codes/{promotion_code}"}),update:B$({method:"POST",fullPath:"/v1/promotion_codes/{promotion_code}"}),list:B$({method:"GET",fullPath:"/v1/promotion_codes",methodType:"list"}),serializeBatchCreate($={},Z={}){let J=BL.randomUUID(),Y=Z.apiVersion||this._stripe.getApiField("version"),X={id:J,params:$,stripe_version:Y};if(Z.stripeContext)X.context=Z.stripeContext;return JSON.stringify(X)},serializeBatchUpdate($,Z={},J={}){let Y=BL.randomUUID(),X=J.apiVersion||this._stripe.getApiField("version"),Q={id:Y,params:Z,stripe_version:X};if(Q.path_params={promotion_code:$},J.stripeContext)Q.context=J.stripeContext;return JSON.stringify(Q)}})});var DL=z((TL)=>{Object.defineProperty(TL,"__esModule",{value:!0});TL.Quotes=void 0;var HL=H(),S=HL.StripeResource.method;TL.Quotes=HL.StripeResource.extend({create:S({method:"POST",fullPath:"/v1/quotes",requestSchema:{kind:"object",fields:{line_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}},status_details:{kind:"nullable",inner:{kind:"object",fields:{stale:{kind:"object",fields:{last_reason:{kind:"nullable",inner:{kind:"object",fields:{subscription_changed:{kind:"object",fields:{previous_subscription:{kind:"nullable",inner:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}}}}}),retrieve:S({method:"GET",fullPath:"/v1/quotes/{quote}",responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}},status_details:{kind:"nullable",inner:{kind:"object",fields:{stale:{kind:"object",fields:{last_reason:{kind:"nullable",inner:{kind:"object",fields:{subscription_changed:{kind:"object",fields:{previous_subscription:{kind:"nullable",inner:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}}}}}),update:S({method:"POST",fullPath:"/v1/quotes/{quote}",requestSchema:{kind:"object",fields:{line_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}},status_details:{kind:"nullable",inner:{kind:"object",fields:{stale:{kind:"object",fields:{last_reason:{kind:"nullable",inner:{kind:"object",fields:{subscription_changed:{kind:"object",fields:{previous_subscription:{kind:"nullable",inner:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}}}}}),list:S({method:"GET",fullPath:"/v1/quotes",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}},status_details:{kind:"nullable",inner:{kind:"object",fields:{stale:{kind:"object",fields:{last_reason:{kind:"nullable",inner:{kind:"object",fields:{subscription_changed:{kind:"object",fields:{previous_subscription:{kind:"nullable",inner:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}),accept:S({method:"POST",fullPath:"/v1/quotes/{quote}/accept",responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}},status_details:{kind:"nullable",inner:{kind:"object",fields:{stale:{kind:"object",fields:{last_reason:{kind:"nullable",inner:{kind:"object",fields:{subscription_changed:{kind:"object",fields:{previous_subscription:{kind:"nullable",inner:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}}}}}),cancel:S({method:"POST",fullPath:"/v1/quotes/{quote}/cancel",responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}},status_details:{kind:"nullable",inner:{kind:"object",fields:{stale:{kind:"object",fields:{last_reason:{kind:"nullable",inner:{kind:"object",fields:{subscription_changed:{kind:"object",fields:{previous_subscription:{kind:"nullable",inner:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}}}}}),finalizeQuote:S({method:"POST",fullPath:"/v1/quotes/{quote}/finalize",responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}},status_details:{kind:"nullable",inner:{kind:"object",fields:{stale:{kind:"object",fields:{last_reason:{kind:"nullable",inner:{kind:"object",fields:{subscription_changed:{kind:"object",fields:{previous_subscription:{kind:"nullable",inner:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}}}}}),listPreviewInvoiceLines:S({method:"GET",fullPath:"/v1/quotes/{quote}/preview_invoices/{preview_invoice}/lines",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),listComputedUpfrontLineItems:S({method:"GET",fullPath:"/v1/quotes/{quote}/computed_upfront_line_items",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}),listLineItems:S({method:"GET",fullPath:"/v1/quotes/{quote}/line_items",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}),listLines:S({method:"GET",fullPath:"/v1/quotes/{quote}/lines",methodType:"list"}),listPreviewInvoices:S({method:"GET",fullPath:"/v1/quotes/{quote}/preview_invoices",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),listPreviewSubscriptionSchedules:S({method:"GET",fullPath:"/v1/quotes/{quote}/preview_subscription_schedules",methodType:"list"}),markDraft:S({method:"POST",fullPath:"/v1/quotes/{quote}/mark_draft",responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}},status_details:{kind:"nullable",inner:{kind:"object",fields:{stale:{kind:"object",fields:{last_reason:{kind:"nullable",inner:{kind:"object",fields:{subscription_changed:{kind:"object",fields:{previous_subscription:{kind:"nullable",inner:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}}}}}),markStale:S({method:"POST",fullPath:"/v1/quotes/{quote}/mark_stale",responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}},status_details:{kind:"nullable",inner:{kind:"object",fields:{stale:{kind:"object",fields:{last_reason:{kind:"nullable",inner:{kind:"object",fields:{subscription_changed:{kind:"object",fields:{previous_subscription:{kind:"nullable",inner:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}}}}}),pdf:S({method:"GET",fullPath:"/v1/quotes/{quote}/pdf",host:"files.stripe.com",streaming:!0}),reestimate:S({method:"POST",fullPath:"/v1/quotes/{quote}/reestimate",responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}},status_details:{kind:"nullable",inner:{kind:"object",fields:{stale:{kind:"object",fields:{last_reason:{kind:"nullable",inner:{kind:"object",fields:{subscription_changed:{kind:"object",fields:{previous_subscription:{kind:"nullable",inner:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}}}}})})});var CL=z((qL)=>{Object.defineProperty(qL,"__esModule",{value:!0});qL.Refunds=void 0;var OL=H(),z8=OL.StripeResource.method;qL.Refunds=OL.StripeResource.extend({create:z8({method:"POST",fullPath:"/v1/refunds"}),retrieve:z8({method:"GET",fullPath:"/v1/refunds/{refund}"}),update:z8({method:"POST",fullPath:"/v1/refunds/{refund}"}),list:z8({method:"GET",fullPath:"/v1/refunds",methodType:"list"}),cancel:z8({method:"POST",fullPath:"/v1/refunds/{refund}/cancel"})})});var AL=z((kL)=>{Object.defineProperty(kL,"__esModule",{value:!0});kL.Reviews=void 0;var FL=H(),s9=FL.StripeResource.method;kL.Reviews=FL.StripeResource.extend({retrieve:s9({method:"GET",fullPath:"/v1/reviews/{review}"}),list:s9({method:"GET",fullPath:"/v1/reviews",methodType:"list"}),approve:s9({method:"POST",fullPath:"/v1/reviews/{review}/approve"})})});var vL=z((IL)=>{Object.defineProperty(IL,"__esModule",{value:!0});IL.SetupAttempts=void 0;var NL=H(),Yw=NL.StripeResource.method;IL.SetupAttempts=NL.StripeResource.extend({list:Yw({method:"GET",fullPath:"/v1/setup_attempts",methodType:"list"})})});var bL=z((SL)=>{Object.defineProperty(SL,"__esModule",{value:!0});SL.SetupIntents=void 0;var yL=H(),B0=yL.StripeResource.method;SL.SetupIntents=yL.StripeResource.extend({create:B0({method:"POST",fullPath:"/v1/setup_intents"}),retrieve:B0({method:"GET",fullPath:"/v1/setup_intents/{intent}"}),update:B0({method:"POST",fullPath:"/v1/setup_intents/{intent}"}),list:B0({method:"GET",fullPath:"/v1/setup_intents",methodType:"list"}),cancel:B0({method:"POST",fullPath:"/v1/setup_intents/{intent}/cancel"}),confirm:B0({method:"POST",fullPath:"/v1/setup_intents/{intent}/confirm"}),verifyMicrodeposits:B0({method:"POST",fullPath:"/v1/setup_intents/{intent}/verify_microdeposits"})})});var gL=z((fL)=>{Object.defineProperty(fL,"__esModule",{value:!0});fL.ShippingRates=void 0;var jL=H(),L$=jL.StripeResource.method;fL.ShippingRates=jL.StripeResource.extend({create:L$({method:"POST",fullPath:"/v1/shipping_rates"}),retrieve:L$({method:"GET",fullPath:"/v1/shipping_rates/{shipping_rate_token}"}),update:L$({method:"POST",fullPath:"/v1/shipping_rates/{shipping_rate_token}"}),list:L$({method:"GET",fullPath:"/v1/shipping_rates",methodType:"list"})})});var uL=z((hL)=>{Object.defineProperty(hL,"__esModule",{value:!0});hL.Sources=void 0;var ML=H(),K8=ML.StripeResource.method;hL.Sources=ML.StripeResource.extend({create:K8({method:"POST",fullPath:"/v1/sources"}),retrieve:K8({method:"GET",fullPath:"/v1/sources/{source}"}),update:K8({method:"POST",fullPath:"/v1/sources/{source}"}),listSourceTransactions:K8({method:"GET",fullPath:"/v1/sources/{source}/source_transactions",methodType:"list"}),verify:K8({method:"POST",fullPath:"/v1/sources/{source}/verify"})})});var pL=z((lL)=>{Object.defineProperty(lL,"__esModule",{value:!0});lL.SubscriptionItems=void 0;var cL=H(),H8=cL.StripeResource.method;lL.SubscriptionItems=cL.StripeResource.extend({create:H8({method:"POST",fullPath:"/v1/subscription_items",requestSchema:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}},responseSchema:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}),retrieve:H8({method:"GET",fullPath:"/v1/subscription_items/{item}",responseSchema:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}),update:H8({method:"POST",fullPath:"/v1/subscription_items/{item}",requestSchema:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}},responseSchema:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}),list:H8({method:"GET",fullPath:"/v1/subscription_items",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),del:H8({method:"DELETE",fullPath:"/v1/subscription_items/{item}"})})});var sL=z((iL)=>{Object.defineProperty(iL,"__esModule",{value:!0});iL.SubscriptionSchedules=void 0;var o9=q("crypto"),dL=H(),L0=dL.StripeResource.method;iL.SubscriptionSchedules=dL.StripeResource.extend({create:L0({method:"POST",fullPath:"/v1/subscription_schedules",requestSchema:{kind:"object",fields:{phases:{kind:"array",element:{kind:"object",fields:{add_invoice_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}}}}}}),retrieve:L0({method:"GET",fullPath:"/v1/subscription_schedules/{schedule}"}),update:L0({method:"POST",fullPath:"/v1/subscription_schedules/{schedule}",requestSchema:{kind:"object",fields:{phases:{kind:"array",element:{kind:"object",fields:{add_invoice_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}}}}}}),list:L0({method:"GET",fullPath:"/v1/subscription_schedules",methodType:"list"}),amend:L0({method:"POST",fullPath:"/v1/subscription_schedules/{schedule}/amend"}),cancel:L0({method:"POST",fullPath:"/v1/subscription_schedules/{schedule}/cancel"}),release:L0({method:"POST",fullPath:"/v1/subscription_schedules/{schedule}/release"}),serializeBatchCancel($,Z={},J={}){let Y=o9.randomUUID(),X=J.apiVersion||this._stripe.getApiField("version"),Q={id:Y,params:Z,stripe_version:X};if(Q.path_params={schedule:$},J.stripeContext)Q.context=J.stripeContext;return JSON.stringify(Q)},serializeBatchCreate($={},Z={}){let J=o9.randomUUID(),Y=Z.apiVersion||this._stripe.getApiField("version"),X={id:J,params:$,stripe_version:Y};if(Z.stripeContext)X.context=Z.stripeContext;return JSON.stringify(X)},serializeBatchUpdate($,Z={},J={}){let Y=o9.randomUUID(),X=J.apiVersion||this._stripe.getApiField("version"),Q={id:Y,params:Z,stripe_version:X};if(Q.path_params={schedule:$},J.stripeContext)Q.context=J.stripeContext;return JSON.stringify(Q)}})});var $U=z((tL)=>{Object.defineProperty(tL,"__esModule",{value:!0});tL.Subscriptions=void 0;var oL=q("crypto"),rL=H(),i=rL.StripeResource.method;tL.Subscriptions=rL.StripeResource.extend({create:i({method:"POST",fullPath:"/v1/subscriptions",requestSchema:{kind:"object",fields:{add_invoice_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}),retrieve:i({method:"GET",fullPath:"/v1/subscriptions/{subscription_exposed_id}",responseSchema:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}),update:i({method:"POST",fullPath:"/v1/subscriptions/{subscription_exposed_id}",requestSchema:{kind:"object",fields:{add_invoice_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}),list:i({method:"GET",fullPath:"/v1/subscriptions",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}),cancel:i({method:"DELETE",fullPath:"/v1/subscriptions/{subscription_exposed_id}",responseSchema:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}),deleteDiscount:i({method:"DELETE",fullPath:"/v1/subscriptions/{subscription_exposed_id}/discount"}),migrate:i({method:"POST",fullPath:"/v1/subscriptions/{subscription}/migrate",responseSchema:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}),resume:i({method:"POST",fullPath:"/v1/subscriptions/{subscription}/resume",responseSchema:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}),search:i({method:"GET",fullPath:"/v1/subscriptions/search",methodType:"search",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}),serializeBatchMigrate($,Z={},J={}){let Y=oL.randomUUID(),X=J.apiVersion||this._stripe.getApiField("version"),Q={id:Y,params:Z,stripe_version:X};if(Q.path_params={subscription:$},J.stripeContext)Q.context=J.stripeContext;return JSON.stringify(Q)},serializeBatchUpdate($,Z={},J={}){let Y=oL.randomUUID(),X=J.apiVersion||this._stripe.getApiField("version"),Q={id:Y,params:Z,stripe_version:X};if(Q.path_params={subscription_exposed_id:$},J.stripeContext)Q.context=J.stripeContext;return JSON.stringify(Q)}})});var QU=z((YU)=>{Object.defineProperty(YU,"__esModule",{value:!0});YU.TaxCodes=void 0;var JU=H(),ZU=JU.StripeResource.method;YU.TaxCodes=JU.StripeResource.extend({retrieve:ZU({method:"GET",fullPath:"/v1/tax_codes/{id}"}),list:ZU({method:"GET",fullPath:"/v1/tax_codes",methodType:"list"})})});var BU=z((WU)=>{Object.defineProperty(WU,"__esModule",{value:!0});WU.TaxIds=void 0;var GU=H(),U$=GU.StripeResource.method;WU.TaxIds=GU.StripeResource.extend({create:U$({method:"POST",fullPath:"/v1/tax_ids"}),retrieve:U$({method:"GET",fullPath:"/v1/tax_ids/{id}"}),list:U$({method:"GET",fullPath:"/v1/tax_ids",methodType:"list"}),del:U$({method:"DELETE",fullPath:"/v1/tax_ids/{id}"})})});var KU=z((UU)=>{Object.defineProperty(UU,"__esModule",{value:!0});UU.TaxRates=void 0;var LU=H(),z$=LU.StripeResource.method;UU.TaxRates=LU.StripeResource.extend({create:z$({method:"POST",fullPath:"/v1/tax_rates"}),retrieve:z$({method:"GET",fullPath:"/v1/tax_rates/{tax_rate}"}),update:z$({method:"POST",fullPath:"/v1/tax_rates/{tax_rate}"}),list:z$({method:"GET",fullPath:"/v1/tax_rates",methodType:"list"})})});var OU=z((wU)=>{Object.defineProperty(wU,"__esModule",{value:!0});wU.Tokens=void 0;var TU=H(),HU=TU.StripeResource.method;wU.Tokens=TU.StripeResource.extend({create:HU({method:"POST",fullPath:"/v1/tokens"}),retrieve:HU({method:"GET",fullPath:"/v1/tokens/{token}"})})});var FU=z((EU)=>{Object.defineProperty(EU,"__esModule",{value:!0});EU.Topups=void 0;var qU=H(),T8=qU.StripeResource.method;EU.Topups=qU.StripeResource.extend({create:T8({method:"POST",fullPath:"/v1/topups"}),retrieve:T8({method:"GET",fullPath:"/v1/topups/{topup}"}),update:T8({method:"POST",fullPath:"/v1/topups/{topup}"}),list:T8({method:"GET",fullPath:"/v1/topups",methodType:"list"}),cancel:T8({method:"POST",fullPath:"/v1/topups/{topup}/cancel"})})});var NU=z((xU)=>{Object.defineProperty(xU,"__esModule",{value:!0});xU.Transfers=void 0;var kU=H(),Z0=kU.StripeResource.method;xU.Transfers=kU.StripeResource.extend({create:Z0({method:"POST",fullPath:"/v1/transfers"}),retrieve:Z0({method:"GET",fullPath:"/v1/transfers/{transfer}"}),update:Z0({method:"POST",fullPath:"/v1/transfers/{transfer}"}),list:Z0({method:"GET",fullPath:"/v1/transfers",methodType:"list"}),createReversal:Z0({method:"POST",fullPath:"/v1/transfers/{id}/reversals"}),listReversals:Z0({method:"GET",fullPath:"/v1/transfers/{id}/reversals",methodType:"list"}),retrieveReversal:Z0({method:"GET",fullPath:"/v1/transfers/{transfer}/reversals/{id}"}),updateReversal:Z0({method:"POST",fullPath:"/v1/transfers/{transfer}/reversals/{id}"})})});var yU=z((PU)=>{Object.defineProperty(PU,"__esModule",{value:!0});PU.WebhookEndpoints=void 0;var IU=H(),w8=IU.StripeResource.method;PU.WebhookEndpoints=IU.StripeResource.extend({create:w8({method:"POST",fullPath:"/v1/webhook_endpoints"}),retrieve:w8({method:"GET",fullPath:"/v1/webhook_endpoints/{webhook_endpoint}"}),update:w8({method:"POST",fullPath:"/v1/webhook_endpoints/{webhook_endpoint}"}),list:w8({method:"GET",fullPath:"/v1/webhook_endpoints",methodType:"list"}),del:w8({method:"DELETE",fullPath:"/v1/webhook_endpoints/{webhook_endpoint}"})})});var RU=z((O)=>{Object.defineProperty(O,"__esModule",{value:!0});O.SetupIntents=O.SetupAttempts=O.Reviews=O.Refunds=O.Quotes=O.PromotionCodes=O.Products=O.Prices=O.Plans=O.Payouts=O.PaymentRecords=O.PaymentMethods=O.PaymentMethodDomains=O.PaymentMethodConfigurations=O.PaymentLinks=O.PaymentIntents=O.PaymentAttemptRecords=O.Orders=O.OAuth=O.Margins=O.Mandates=O.Invoices=O.InvoiceRenderingTemplates=O.InvoicePayments=O.InvoiceItems=O.FxQuotes=O.Files=O.FileLinks=O.ExternalAccounts=O.ExchangeRates=O.Events=O.EphemeralKeys=O.Disputes=O.Customers=O.CustomerSessions=O.CreditNotes=O.Coupons=O.CountrySpecs=O.ConfirmationTokens=O.Charges=O.BalanceTransactions=O.BalanceSettings=O.Balance=O.ApplicationFees=O.ApplePayDomains=O.Accounts=O.AccountSessions=O.AccountNotices=O.AccountLinks=O.Account=void 0;O.V2=O.Treasury=O.TestHelpers=O.Terminal=O.Tax=O.Sigma=O.Reserve=O.Reporting=O.Radar=O.ProductCatalog=O.Privacy=O.Issuing=O.Identity=O.Forwarding=O.FinancialConnections=O.Entitlements=O.Climate=O.Checkout=O.Capital=O.BillingPortal=O.Billing=O.Apps=O.WebhookEndpoints=O.Transfers=O.Topups=O.Tokens=O.TaxRates=O.TaxIds=O.TaxCodes=O.Subscriptions=O.SubscriptionSchedules=O.SubscriptionItems=O.Sources=O.ShippingRates=void 0;var x=J6(),Xw=G6(),Qw=U6(),Gw=T6(),Ww=I6(),Vw=R6(),Bw=g6(),Lw=u6(),Uw=p6(),zw=s6(),Kw=e6(),Hw=Y1(),Tw=W1(),ww=T1(),Dw=q1(),Ow=k1(),qw=I1(),Ew=S1(),Cw=f1(),Fw=l1(),kw=i1(),xw=r1(),Aw=Z7(),Nw=Q7(),Iw=B7(),Pw=H7(),vw=O7(),yw=F7(),Sw=N7(),Rw=y7(),bw=j7(),jw=h7(),fw=l7(),_w=a7(),gw=t7(),Mw=J5(),hw=G5(),mw=L5(),uw=H5(),cw=O5(),lw=k5(),nw=I5(),pw=S5(),dw=_5(),iw=m5(),aw=p5(),sw=s5(),ow=$J(),rw=XJ(),tw=VJ(),ew=zJ(),$D=DJ(),ZD=CJ(),JD=AJ(),YD=vJ(),XD=bJ(),QD=gJ(),GD=uJ(),WD=pJ(),VD=sJ(),BD=eJ(),LD=YY(),UD=WY(),zD=UY(),KD=wY(),HD=EY(),TD=xY(),wD=PY(),DD=RY(),OD=_Y(),qD=mY(),ED=nY(),CD=aY(),FD=tY(),kD=J3(),xD=G3(),AD=L3(),ND=T3(),ID=q3(),PD=x3(),vD=P3(),yD=R3(),SD=_3(),RD=m3(),bD=n3(),jD=s3(),fD=$X(),_D=XX(),gD=BX(),MD=HX(),hD=OX(),mD=FX(),uD=NX(),cD=SX(),lD=fX(),nD=mX(),pD=nX(),dD=sX(),iD=eX(),aD=YQ(),sD=WQ(),oD=zQ(),rD=DQ(),tD=FQ(),eD=NQ(),$O=yQ(),ZO=fQ(),JO=mQ(),YO=pQ(),XO=sQ(),QO=eQ(),GO=YG(),WO=VG(),VO=KG(),BO=DG(),LO=CG(),UO=AG(),zO=vG(),KO=jG(),HO=MG(),TO=n9();Object.defineProperty(O,"Account",{enumerable:!0,get:function(){return TO.Accounts}});var wO=pG();Object.defineProperty(O,"AccountLinks",{enumerable:!0,get:function(){return wO.AccountLinks}});var DO=sG();Object.defineProperty(O,"AccountNotices",{enumerable:!0,get:function(){return DO.AccountNotices}});var OO=eG();Object.defineProperty(O,"AccountSessions",{enumerable:!0,get:function(){return OO.AccountSessions}});var qO=n9();Object.defineProperty(O,"Accounts",{enumerable:!0,get:function(){return qO.Accounts}});var EO=YW();Object.defineProperty(O,"ApplePayDomains",{enumerable:!0,get:function(){return EO.ApplePayDomains}});var CO=WW();Object.defineProperty(O,"ApplicationFees",{enumerable:!0,get:function(){return CO.ApplicationFees}});var FO=UW();Object.defineProperty(O,"Balance",{enumerable:!0,get:function(){return FO.Balance}});var kO=wW();Object.defineProperty(O,"BalanceSettings",{enumerable:!0,get:function(){return kO.BalanceSettings}});var xO=CW();Object.defineProperty(O,"BalanceTransactions",{enumerable:!0,get:function(){return xO.BalanceTransactions}});var AO=AW();Object.defineProperty(O,"Charges",{enumerable:!0,get:function(){return AO.Charges}});var NO=vW();Object.defineProperty(O,"ConfirmationTokens",{enumerable:!0,get:function(){return NO.ConfirmationTokens}});var IO=jW();Object.defineProperty(O,"CountrySpecs",{enumerable:!0,get:function(){return IO.CountrySpecs}});var PO=MW();Object.defineProperty(O,"Coupons",{enumerable:!0,get:function(){return PO.Coupons}});var vO=cW();Object.defineProperty(O,"CreditNotes",{enumerable:!0,get:function(){return vO.CreditNotes}});var yO=dW();Object.defineProperty(O,"CustomerSessions",{enumerable:!0,get:function(){return yO.CustomerSessions}});var SO=oW();Object.defineProperty(O,"Customers",{enumerable:!0,get:function(){return SO.Customers}});var RO=$V();Object.defineProperty(O,"Disputes",{enumerable:!0,get:function(){return RO.Disputes}});var bO=QV();Object.defineProperty(O,"EphemeralKeys",{enumerable:!0,get:function(){return bO.EphemeralKeys}});var jO=LV();Object.defineProperty(O,"Events",{enumerable:!0,get:function(){return jO.Events}});var fO=TV();Object.defineProperty(O,"ExchangeRates",{enumerable:!0,get:function(){return fO.ExchangeRates}});var _O=qV();Object.defineProperty(O,"ExternalAccounts",{enumerable:!0,get:function(){return _O.ExternalAccounts}});var gO=kV();Object.defineProperty(O,"FileLinks",{enumerable:!0,get:function(){return gO.FileLinks}});var MO=SV();Object.defineProperty(O,"Files",{enumerable:!0,get:function(){return MO.Files}});var hO=fV();Object.defineProperty(O,"FxQuotes",{enumerable:!0,get:function(){return hO.FxQuotes}});var mO=hV();Object.defineProperty(O,"InvoiceItems",{enumerable:!0,get:function(){return mO.InvoiceItems}});var uO=nV();Object.defineProperty(O,"InvoicePayments",{enumerable:!0,get:function(){return uO.InvoicePayments}});var cO=aV();Object.defineProperty(O,"InvoiceRenderingTemplates",{enumerable:!0,get:function(){return cO.InvoiceRenderingTemplates}});var lO=eV();Object.defineProperty(O,"Invoices",{enumerable:!0,get:function(){return lO.Invoices}});var nO=XB();Object.defineProperty(O,"Mandates",{enumerable:!0,get:function(){return nO.Mandates}});var pO=VB();Object.defineProperty(O,"Margins",{enumerable:!0,get:function(){return pO.Margins}});var dO=KB();Object.defineProperty(O,"OAuth",{enumerable:!0,get:function(){return dO.OAuth}});var iO=DB();Object.defineProperty(O,"Orders",{enumerable:!0,get:function(){return iO.Orders}});var aO=FB();Object.defineProperty(O,"PaymentAttemptRecords",{enumerable:!0,get:function(){return aO.PaymentAttemptRecords}});var sO=NB();Object.defineProperty(O,"PaymentIntents",{enumerable:!0,get:function(){return sO.PaymentIntents}});var oO=yB();Object.defineProperty(O,"PaymentLinks",{enumerable:!0,get:function(){return oO.PaymentLinks}});var rO=jB();Object.defineProperty(O,"PaymentMethodConfigurations",{enumerable:!0,get:function(){return rO.PaymentMethodConfigurations}});var tO=MB();Object.defineProperty(O,"PaymentMethodDomains",{enumerable:!0,get:function(){return tO.PaymentMethodDomains}});var eO=cB();Object.defineProperty(O,"PaymentMethods",{enumerable:!0,get:function(){return eO.PaymentMethods}});var $q=dB();Object.defineProperty(O,"PaymentRecords",{enumerable:!0,get:function(){return $q.PaymentRecords}});var Zq=oB();Object.defineProperty(O,"Payouts",{enumerable:!0,get:function(){return Zq.Payouts}});var Jq=$L();Object.defineProperty(O,"Plans",{enumerable:!0,get:function(){return Jq.Plans}});var Yq=XL();Object.defineProperty(O,"Prices",{enumerable:!0,get:function(){return Yq.Prices}});var Xq=VL();Object.defineProperty(O,"Products",{enumerable:!0,get:function(){return Xq.Products}});var Qq=KL();Object.defineProperty(O,"PromotionCodes",{enumerable:!0,get:function(){return Qq.PromotionCodes}});var Gq=DL();Object.defineProperty(O,"Quotes",{enumerable:!0,get:function(){return Gq.Quotes}});var Wq=CL();Object.defineProperty(O,"Refunds",{enumerable:!0,get:function(){return Wq.Refunds}});var Vq=AL();Object.defineProperty(O,"Reviews",{enumerable:!0,get:function(){return Vq.Reviews}});var Bq=vL();Object.defineProperty(O,"SetupAttempts",{enumerable:!0,get:function(){return Bq.SetupAttempts}});var Lq=bL();Object.defineProperty(O,"SetupIntents",{enumerable:!0,get:function(){return Lq.SetupIntents}});var Uq=gL();Object.defineProperty(O,"ShippingRates",{enumerable:!0,get:function(){return Uq.ShippingRates}});var zq=uL();Object.defineProperty(O,"Sources",{enumerable:!0,get:function(){return zq.Sources}});var Kq=pL();Object.defineProperty(O,"SubscriptionItems",{enumerable:!0,get:function(){return Kq.SubscriptionItems}});var Hq=sL();Object.defineProperty(O,"SubscriptionSchedules",{enumerable:!0,get:function(){return Hq.SubscriptionSchedules}});var Tq=$U();Object.defineProperty(O,"Subscriptions",{enumerable:!0,get:function(){return Tq.Subscriptions}});var wq=QU();Object.defineProperty(O,"TaxCodes",{enumerable:!0,get:function(){return wq.TaxCodes}});var Dq=BU();Object.defineProperty(O,"TaxIds",{enumerable:!0,get:function(){return Dq.TaxIds}});var Oq=KU();Object.defineProperty(O,"TaxRates",{enumerable:!0,get:function(){return Oq.TaxRates}});var qq=OU();Object.defineProperty(O,"Tokens",{enumerable:!0,get:function(){return qq.Tokens}});var Eq=FU();Object.defineProperty(O,"Topups",{enumerable:!0,get:function(){return Eq.Topups}});var Cq=NU();Object.defineProperty(O,"Transfers",{enumerable:!0,get:function(){return Cq.Transfers}});var Fq=yU();Object.defineProperty(O,"WebhookEndpoints",{enumerable:!0,get:function(){return Fq.WebhookEndpoints}});O.Apps=(0,x.resourceNamespace)("apps",{Secrets:iD.Secrets});O.Billing=(0,x.resourceNamespace)("billing",{Alerts:Lw.Alerts,CreditBalanceSummary:Iw.CreditBalanceSummary,CreditBalanceTransactions:Pw.CreditBalanceTransactions,CreditGrants:vw.CreditGrants,MeterEventAdjustments:YD.MeterEventAdjustments,MeterEvents:WD.MeterEvents,Meters:LD.Meters,Analytics:(0,x.resourceNamespace)("analytics",{MeterUsage:BD.MeterUsage})});O.BillingPortal=(0,x.resourceNamespace)("billingPortal",{Configurations:kw.Configurations,Sessions:aD.Sessions});O.Capital=(0,x.resourceNamespace)("capital",{FinancingOffers:nw.FinancingOffers,FinancingSummary:pw.FinancingSummary,FinancingTransactions:dw.FinancingTransactions});O.Checkout=(0,x.resourceNamespace)("checkout",{Sessions:sD.Sessions});O.Climate=(0,x.resourceNamespace)("climate",{Orders:zD.Orders,Products:PD.Products,Suppliers:tD.Suppliers});O.Entitlements=(0,x.resourceNamespace)("entitlements",{ActiveEntitlements:Vw.ActiveEntitlements,Features:hw.Features});O.FinancialConnections=(0,x.resourceNamespace)("financialConnections",{Accounts:Gw.Accounts,Authorizations:zw.Authorizations,Institutions:$D.Institutions,Sessions:oD.Sessions,Transactions:YO.Transactions});O.Forwarding=(0,x.resourceNamespace)("forwarding",{Requests:pD.Requests});O.Identity=(0,x.resourceNamespace)("identity",{VerificationReports:KO.VerificationReports,VerificationSessions:HO.VerificationSessions});O.Issuing=(0,x.resourceNamespace)("issuing",{Authorizations:Kw.Authorizations,Cardholders:qw.Cardholders,Cards:Ew.Cards,CreditUnderwritingRecords:Sw.CreditUnderwritingRecords,DisputeSettlementDetails:jw.DisputeSettlementDetails,Disputes:fw.Disputes,FraudLiabilityDebits:aw.FraudLiabilityDebits,PersonalizationDesigns:xD.PersonalizationDesigns,PhysicalBundles:ND.PhysicalBundles,Tokens:$O.Tokens,Transactions:XO.Transactions});O.Privacy=(0,x.resourceNamespace)("privacy",{RedactionJobs:hD.RedactionJobs});O.ProductCatalog=(0,x.resourceNamespace)("productCatalog",{TrialOffers:BO.TrialOffers});O.Radar=(0,x.resourceNamespace)("radar",{EarlyFraudWarnings:_w.EarlyFraudWarnings,PaymentEvaluations:CD.PaymentEvaluations,ValueListItems:UO.ValueListItems,ValueLists:zO.ValueLists});O.Reporting=(0,x.resourceNamespace)("reporting",{ReportRuns:lD.ReportRuns,ReportTypes:nD.ReportTypes});O.Reserve=(0,x.resourceNamespace)("reserve",{Holds:ow.Holds,Plans:ID.Plans,Releases:cD.Releases});O.Sigma=(0,x.resourceNamespace)("sigma",{ScheduledQueryRuns:dD.ScheduledQueryRuns});O.Tax=(0,x.resourceNamespace)("tax",{Associations:Uw.Associations,Calculations:Ow.Calculations,Forms:iw.Forms,Locations:ZD.Locations,Registrations:uD.Registrations,Settings:rD.Settings,Transactions:QO.Transactions});O.Terminal=(0,x.resourceNamespace)("terminal",{Configurations:xw.Configurations,ConnectionTokens:Nw.ConnectionTokens,Locations:JD.Locations,OnboardingLinks:UD.OnboardingLinks,ReaderCollectedData:yD.ReaderCollectedData,Readers:SD.Readers});O.TestHelpers=(0,x.resourceNamespace)("testHelpers",{ConfirmationTokens:Aw.ConfirmationTokens,Customers:Rw.Customers,Refunds:mD.Refunds,TestClocks:eD.TestClocks,Issuing:(0,x.resourceNamespace)("issuing",{Authorizations:Hw.Authorizations,Cards:Cw.Cards,PersonalizationDesigns:AD.PersonalizationDesigns,Transactions:GO.Transactions}),Terminal:(0,x.resourceNamespace)("terminal",{Readers:RD.Readers}),Treasury:(0,x.resourceNamespace)("treasury",{InboundTransfers:rw.InboundTransfers,OutboundPayments:HD.OutboundPayments,OutboundTransfers:OD.OutboundTransfers,ReceivedCredits:bD.ReceivedCredits,ReceivedDebits:_D.ReceivedDebits})});O.Treasury=(0,x.resourceNamespace)("treasury",{CreditReversals:yw.CreditReversals,DebitReversals:bw.DebitReversals,FinancialAccounts:mw.FinancialAccounts,InboundTransfers:tw.InboundTransfers,OutboundPayments:TD.OutboundPayments,OutboundTransfers:qD.OutboundTransfers,ReceivedCredits:jD.ReceivedCredits,ReceivedDebits:gD.ReceivedDebits,TransactionEntries:ZO.TransactionEntries,Transactions:WO.Transactions});O.V2=(0,x.resourceNamespace)("v2",{Billing:(0,x.resourceNamespace)("billing",{BillSettings:ww.BillSettings,Cadences:Dw.Cadences,CollectionSettings:Fw.CollectionSettings,MeterEventAdjustments:XD.MeterEventAdjustments,MeterEventSession:QD.MeterEventSession,MeterEventStream:GD.MeterEventStream,MeterEvents:VD.MeterEvents,Profiles:vD.Profiles}),Core:(0,x.resourceNamespace)("core",{AccountLinks:Xw.AccountLinks,AccountTokens:Qw.AccountTokens,Accounts:Ww.Accounts,BatchJobs:Tw.BatchJobs,EventDestinations:gw.EventDestinations,Events:Mw.Events,Vault:(0,x.resourceNamespace)("vault",{GbBankAccounts:sw.GbBankAccounts,UsBankAccounts:LO.UsBankAccounts})}),MoneyManagement:(0,x.resourceNamespace)("moneyManagement",{Adjustments:Bw.Adjustments,FinancialAccounts:uw.FinancialAccounts,FinancialAddresses:cw.FinancialAddresses,InboundTransfers:ew.InboundTransfers,OutboundPaymentQuotes:KD.OutboundPaymentQuotes,OutboundPayments:wD.OutboundPayments,OutboundSetupIntents:DD.OutboundSetupIntents,OutboundTransfers:ED.OutboundTransfers,PayoutMethods:FD.PayoutMethods,PayoutMethodsBankAccountSpec:kD.PayoutMethodsBankAccountSpec,ReceivedCredits:fD.ReceivedCredits,ReceivedDebits:MD.ReceivedDebits,TransactionEntries:JO.TransactionEntries,Transactions:VO.Transactions}),TestHelper:(0,x.resourceNamespace)("testHelper",{FinancialAddresses:lw.FinancialAddresses})})});var _U=z((jU)=>{Object.defineProperty(jU,"__esModule",{value:!0});jU.StripeEventNotificationHandler=void 0;var pq=new Set(["v1.billing.meter.error_report_triggered","v1.billing.meter.no_meter_found","v2.core.account.closed","v2.core.account.created","v2.core.account.updated","v2.core.account[configuration.customer].capability_status_updated","v2.core.account[configuration.customer].updated","v2.core.account[configuration.merchant].capability_status_updated","v2.core.account[configuration.merchant].updated","v2.core.account[configuration.recipient].capability_status_updated","v2.core.account[configuration.recipient].updated","v2.core.account[configuration.storer].capability_status_updated","v2.core.account[configuration.storer].updated","v2.core.account[defaults].updated","v2.core.account[future_requirements].updated","v2.core.account[identity].updated","v2.core.account[requirements].updated","v2.core.account_link.returned","v2.core.account_person.created","v2.core.account_person.deleted","v2.core.account_person.updated","v2.core.batch_job.batch_failed","v2.core.batch_job.canceled","v2.core.batch_job.completed","v2.core.batch_job.created","v2.core.batch_job.ready_for_upload","v2.core.batch_job.timeout","v2.core.batch_job.updated","v2.core.batch_job.upload_timeout","v2.core.batch_job.validating","v2.core.batch_job.validation_failed","v2.core.event_destination.ping","v2.core.health.event_generation_failure.resolved","v2.money_management.adjustment.created","v2.money_management.financial_account.created","v2.money_management.financial_account.updated","v2.money_management.financial_address.activated","v2.money_management.financial_address.failed","v2.money_management.inbound_transfer.available","v2.money_management.inbound_transfer.bank_debit_failed","v2.money_management.inbound_transfer.bank_debit_processing","v2.money_management.inbound_transfer.bank_debit_queued","v2.money_management.inbound_transfer.bank_debit_returned","v2.money_management.inbound_transfer.bank_debit_succeeded","v2.money_management.outbound_payment.canceled","v2.money_management.outbound_payment.created","v2.money_management.outbound_payment.failed","v2.money_management.outbound_payment.posted","v2.money_management.outbound_payment.returned","v2.money_management.outbound_payment.updated","v2.money_management.outbound_transfer.canceled","v2.money_management.outbound_transfer.created","v2.money_management.outbound_transfer.failed","v2.money_management.outbound_transfer.posted","v2.money_management.outbound_transfer.returned","v2.money_management.outbound_transfer.updated","v2.money_management.payout_method.created","v2.money_management.payout_method.updated","v2.money_management.received_credit.available","v2.money_management.received_credit.failed","v2.money_management.received_credit.returned","v2.money_management.received_credit.succeeded","v2.money_management.received_debit.canceled","v2.money_management.received_debit.failed","v2.money_management.received_debit.pending","v2.money_management.received_debit.succeeded","v2.money_management.received_debit.updated","v2.money_management.transaction.created","v2.money_management.transaction.updated"]);class bU{constructor($,Z,J){this.client=$,this.webhookSecret=Z,this.fallbackCallback=J,this.registeredHandlers={},this.hasHandledEvent=!1}on($,Z){if(this.hasHandledEvent)throw Error("Cannot register new handlers after an event has been handled. This is indicative of a bug.");if(this.registeredHandlers[$])throw Error(`Handler already registered for event type: ${$}`);return this.registeredHandlers[$]=Z,this}registeredEventTypes(){let $=Object.keys(this.registeredHandlers);return $.sort(),$}async handle($,Z){this.hasHandledEvent=!0;let J=this.client.parseEventNotification($,Z,this.webhookSecret),Y=Object.create(Object.getPrototypeOf(this.client));Object.assign(Y,this.client),Y._api={...this.client._api,stripeContext:J.context};let X=this.registeredHandlers[J.type];if(X)return await X(J,Y);else return await this.fallbackCallback(J,Y,{isKnownEventType:pq.has(J.type)})}}jU.StripeEventNotificationHandler=bU});var tU=z((oU)=>{Object.defineProperty(oU,"__esModule",{value:!0});oU.createStripe=void 0;var gU=m0(),dq=NZ(),aU=H(),MU=iZ(),iq=oZ(),sU=eZ(),aq=g0(),hU=M0(),K$=RU(),U0=l(),sq=_U(),mU="api.stripe.com",uU="443",cU="/v1/",lU=sU.ApiVersion,nU=80000,pU=5,dU=0.5,oq=["name","version","url","partner_id"],iU=["authenticator","apiVersion","typescript","maxNetworkRetries","httpAgent","httpClient","timeout","host","port","protocol","telemetry","appInfo","stripeAccount","stripeContext"],rq=($)=>new dq.RequestSender($,aU.StripeResource.MAX_BUFFERED_REQUEST_METRICS);function tq($,Z=rq){Y.PACKAGE_VERSION="21.1.0-beta.1",Y.API_VERSION=sU.ApiVersion;let J=typeof process<"u"&&process.env?(0,U0.detectAIAgent)(process.env):"";Y.AI_AGENT=J,Y.USER_AGENT={bindings_version:Y.PACKAGE_VERSION,lang:"node",typescript:!1,...(0,U0.determineProcessUserAgentProperties)(),...J?{ai_agent:J}:{}},Y.StripeResource=aU.StripeResource,Y.StripeContext=MU.StripeContext,Y.resources=K$,Y.HttpClient=hU.HttpClient,Y.HttpClientResponse=hU.HttpClientResponse,Y.CryptoProvider=aq.CryptoProvider,Y.webhooks=(0,iq.createWebhooks)($);function Y(X,Q={}){if(!(this instanceof Y))return new Y(X,Q);let G=this._getPropsFromConfig(Q);this._platformFunctions=$,Object.defineProperty(this,"_emitter",{value:this._platformFunctions.createEmitter(),enumerable:!1,configurable:!1,writable:!1}),this.VERSION=Y.PACKAGE_VERSION,this.on=this._emitter.on.bind(this._emitter),this.once=this._emitter.once.bind(this._emitter),this.off=this._emitter.removeListener.bind(this._emitter);let W=G.httpAgent||null;this._api={host:G.host||mU,port:G.port||uU,protocol:G.protocol||"https",basePath:cU,version:G.apiVersion||lU,timeout:(0,U0.validateInteger)("timeout",G.timeout,nU),maxNetworkRetries:(0,U0.validateInteger)("maxNetworkRetries",G.maxNetworkRetries,2),agent:W,httpClient:G.httpClient||(W?this._platformFunctions.createNodeHttpClient(W):this._platformFunctions.createDefaultHttpClient()),dev:!1,stripeAccount:G.stripeAccount||null,stripeContext:G.stripeContext||null};let L=G.typescript||!1;if(L!==Y.USER_AGENT.typescript)Y.USER_AGENT.typescript=L;if(G.appInfo)this._setAppInfo(G.appInfo);this._prepResources(),this._setAuthenticator(X,G.authenticator),this.errors=gU,this.webhooks=Y.webhooks,this._prevRequestMetrics=[],this._enableTelemetry=G.telemetry!==!1,this._requestSender=Z(this),this.StripeResource=Y.StripeResource}return Y.errors=gU,Y.createNodeHttpClient=$.createNodeHttpClient,Y.createFetchHttpClient=$.createFetchHttpClient,Y.createNodeCryptoProvider=$.createNodeCryptoProvider,Y.createSubtleCryptoProvider=$.createSubtleCryptoProvider,Y.prototype={_appInfo:void 0,on:null,off:null,once:null,VERSION:null,StripeResource:null,webhooks:null,errors:null,_api:null,_prevRequestMetrics:null,_emitter:null,_enableTelemetry:null,_requestSender:null,_platformFunctions:null,rawRequest(X,Q,G,W){return this._requestSender._rawRequest(X,Q,G,W)},_setAuthenticator(X,Q){if(X&&Q)throw Error("Can't specify both apiKey and authenticator");if(!X&&!Q)throw Error("Neither apiKey nor config.authenticator provided");this._authenticator=X?(0,U0.createApiKeyAuthenticator)(X):Q},_setAppInfo(X){if(X&&typeof X!=="object")throw Error("AppInfo must be an object.");if(X&&!X.name)throw Error("AppInfo.name is required");X=X||{},this._appInfo=oq.reduce((Q,G)=>{if(typeof X[G]=="string")Q=Q||{},Q[G]=X[G];return Q},{})},_setApiField(X,Q){this._api[X]=Q},getApiField(X){return this._api[X]},setClientId(X){this._clientId=X},getClientId(){return this._clientId},getConstant:(X)=>{switch(X){case"DEFAULT_HOST":return mU;case"DEFAULT_PORT":return uU;case"DEFAULT_BASE_PATH":return cU;case"DEFAULT_API_VERSION":return lU;case"DEFAULT_TIMEOUT":return nU;case"MAX_NETWORK_RETRY_DELAY_SEC":return pU;case"INITIAL_NETWORK_RETRY_DELAY_SEC":return dU}return Y[X]},getMaxNetworkRetries(){return this.getApiField("maxNetworkRetries")},_setApiNumberField(X,Q,G){let W=(0,U0.validateInteger)(X,Q,G);this._setApiField(X,W)},getMaxNetworkRetryDelay(){return pU},getInitialNetworkRetryDelay(){return dU},getClientUserAgent(X){return this.getClientUserAgentSeeded(Y.USER_AGENT,X)},getClientUserAgentSeeded(X,Q){let G={};for(let B in X){if(!Object.prototype.hasOwnProperty.call(X,B))continue;G[B]=encodeURIComponent(X[B]??"null")}let W=this._platformFunctions.getPlatformInfo();if(W&&this.getTelemetryEnabled())G.platform=encodeURIComponent(W);else delete G.platform;let L=this.getApiField("httpClient");if(L)G.httplib=encodeURIComponent(L.getClientName());if(this._appInfo)G.application=this._appInfo;Q(JSON.stringify(G))},getAppInfoAsString(){if(!this._appInfo)return"";let X=this._appInfo.name;if(this._appInfo.version)X+=`/${this._appInfo.version}`;if(this._appInfo.url)X+=` (${this._appInfo.url})`;return X},getTelemetryEnabled(){return this._enableTelemetry},_prepResources(){for(let X in K$){if(!Object.prototype.hasOwnProperty.call(K$,X))continue;this[(0,U0.pascalToCamelCase)(X)]=new K$[X](this)}},_getPropsFromConfig(X){if(!X)return{};let Q=typeof X==="string";if(!(X===Object(X)&&!Array.isArray(X))&&!Q)throw Error("Config must either be an object or a string");if(Q)return{apiVersion:X};if(Object.keys(X).filter((L)=>!iU.includes(L)).length>0)throw Error(`Config object may only contain the following: ${iU.join(", ")}`);return X},parseEventNotification(X,Q,G,W,L,B){this.webhooks.signature.verifyHeader(X,Q,G,W||this.webhooks.DEFAULT_TOLERANCE,L,B);let V=X instanceof Uint8Array?JSON.parse(new TextDecoder("utf8").decode(X)):JSON.parse(X);if(V&&V.object==="event")throw Error("You passed a webhook payload to stripe.parseEventNotification, which expects an event notification. Use stripe.webhooks.constructEvent instead.");if(V.context)V.context=MU.StripeContext.parse(V.context);return V.fetchEvent=()=>{return this._requestSender._rawRequest("GET",`/v2/core/events/${V.id}`,void 0,{stripeContext:V.context,headers:{"Stripe-Request-Trigger":`event=${V.id}`}},["fetch_event"])},V.fetchRelatedObject=()=>{if(!V.related_object)return Promise.resolve(null);return this._requestSender._rawRequest("GET",V.related_object.url,void 0,{stripeContext:V.context,headers:{"Stripe-Request-Trigger":`event=${V.id}`}},["fetch_related_object"])},V},notificationHandler(X,Q){return new sq.StripeEventNotificationHandler(this,X,Q)}},Y}oU.createStripe=tq});var $z=z((eU,D8)=>{Object.defineProperty(eU,"__esModule",{value:!0});var eq=FZ(),$E=tU(),ZE=F9(),r9=(0,$E.createStripe)(new eq.NodePlatformFunctions);D8.exports=r9;D8.exports.Stripe=r9;D8.exports.default=r9;D8.exports.Decimal=ZE.Decimal});import"@stacksjs/validation";import{log as O$}from"@stacksjs/cli";import{db as Y4}from"@stacksjs/database";async function Rz($,Z={}){let{olderThanDays:J=30,column:Y="created_at",query:X}=Z;try{if(X){let B=Y4.deleteFrom($);B=X(B);let V=await B.execute(),U=Array.isArray(V)?V:[V],K=Number(U[0]?.numDeletedRows??U.length??0);return O$.info(`Pruned ${K} records from ${$}`),K}let Q=new Date;Q.setDate(Q.getDate()-J);let G=await Y4.deleteFrom($).where(Y,"<",Q.toISOString()).execute(),W=Array.isArray(G)?G:[G],L=Number(W[0]?.numDeletedRows??W.length??0);return O$.info(`Pruned ${L} records from ${$} older than ${J} days`),L}catch(Q){throw O$.error(`Failed to prune ${$}:`,Q),Q}}async function oC($,Z={}){return Rz($,Z)}function rC($){if(!$?.prunable)return null;if(typeof $.prunable==="boolean")return{olderThanDays:30,column:"created_at"};return $.prunable}import{createCipheriv as bz,createDecipheriv as jz,createHash as fz,randomBytes as _z}from"crypto";import{log as k8}from"@stacksjs/logging";var X4="enc:",Q4="aes-256-gcm",gz=12,F8=null;async function G4(){if(F8)return F8;let $=process.env.APP_KEY;if(!$)try{$=(await import("@stacksjs/config").catch(()=>null))?.config?.app?.key}catch{}if(!$)return null;return F8=fz("sha256").update($).digest(),F8}function b0($){return typeof $==="string"&&$.startsWith(X4)}async function q$($){if($==null)return $;if(b0($))return $;if(typeof $!=="string")return $;let Z=await G4();if(!Z)return k8.warn("[orm] encrypted attribute: APP_KEY not set \u2014 storing value in plaintext"),$;let J=_z(gz),Y=bz(Q4,Z,J),X=Buffer.concat([Y.update($,"utf8"),Y.final()]),Q=Y.getAuthTag();return`${X4}${J.toString("base64")}:${Q.toString("base64")}:${X.toString("base64")}`}async function E$($){if($==null)return $;if(typeof $!=="string")return $;if(!b0($))return $;try{let Z=await G4();if(!Z)return k8.warn("[orm] encrypted attribute: APP_KEY not set \u2014 cannot decrypt"),null;let[,J,Y,X]=$.split(":");if(!J||!Y||!X)return k8.warn("[orm] encrypted attribute: malformed envelope, returning null"),null;let Q=Buffer.from(J,"base64"),G=Buffer.from(Y,"base64"),W=Buffer.from(X,"base64"),L=jz(Q4,Z,Q);return L.setAuthTag(G),Buffer.concat([L.update(W),L.final()]).toString("utf8")}catch(Z){return k8.warn("[orm] encrypted attribute: decrypt failed (key rotation? corrupted ciphertext?)",{error:Z}),null}}function C$($){let Z=$.attributes;if(!Z||typeof Z!=="object")return[];let J=[];for(let[Y,X]of Object.entries(Z))if(X&&typeof X==="object"&&X.encrypted===!0)J.push(Y);return J}import{log as f0}from"@stacksjs/logging";var Mz=[/^password$/i,/^password_hash$/i,/^api_key$/i,/_token$/i,/_secret$/i,/^remember_token$/i],V4="model_audits",x$=null;function hz($){x$=$}async function F$(){if(x$!=null)return x$;try{let $=await import("@stacksjs/router").catch(()=>null);if(!$)return null;let Z=$.getCurrentRequest;if(typeof Z!=="function")return null;let J=Z();if(!J)return null;return(J.user??J._user)?.id??null}catch{return null}}function x8($){if(!$||typeof $!=="object")return null;let Z={};for(let[J,Y]of Object.entries($)){if(Mz.some((X)=>X.test(J)))continue;Z[J]=Y}return Z}function j0($){if(!$||typeof $!=="object")return null;let Z=$;if(Z._attributes&&typeof Z._attributes==="object")return{...Z._attributes};return{...$}}function mz($,Z){if(!$||!Z)return{old:$,next:Z};let J={},Y={},X=new Set([...Object.keys($),...Object.keys(Z)]);for(let Q of X)if($[Q]!==Z[Q])J[Q]=$[Q],Y[Q]=Z[Q];return{old:J,next:Y}}async function k$($,Z=!1){try{let{db:J}=await import("@stacksjs/database");await J.insertInto(V4).values({auditable_type:$.auditable_type,auditable_id:$.auditable_id,event:$.event,old_values:$.old_values?JSON.stringify($.old_values):null,new_values:$.new_values?JSON.stringify($.new_values):null,user_id:$.user_id,created_at:new Date().toISOString()}).executeTakeFirst()}catch(J){if(f0.warn(`[orm] audit row write failed for ${$.auditable_type}#${String($.auditable_id)} (${$.event})`,{error:J}),Z)throw J}}function B4($){return{async audits(Z){try{let{db:J}=await import("@stacksjs/database");return(await J.selectFrom(V4).selectAll().where("auditable_type","=",$).where("auditable_id","=",Z).orderBy("created_at","desc").execute()??[]).map((X)=>({...X,old_values:typeof X.old_values==="string"?W4(X.old_values):X.old_values,new_values:typeof X.new_values==="string"?W4(X.new_values):X.new_values}))}catch(J){return f0.warn(`[orm] audits() lookup failed for ${$}#${String(Z)}`,{error:J}),[]}}}}function W4($){try{return JSON.parse($)}catch{return $}}function L4($){if($&&typeof $==="object"&&"transactional"in $)return{transactional:$.transactional===!0};return{transactional:!1}}function U4($,Z,J="id",Y={}){let X=Y.transactional===!0,Q=$;if(typeof $.audits!=="function")$.audits=B4(Z).audits;let G=async(V)=>{if(!X)return await V();let{db:U}=await import("@stacksjs/database");return await U.transaction(async()=>V())},W=$.create;if(typeof W==="function")$.create=async function(...V){return await G(async()=>{let U=await W.apply(this,V);try{let K=j0(U),T=K?.[J];if(T!=null){let w=await F$();await k$({auditable_type:Z,auditable_id:T,event:"created",old_values:null,new_values:x8(K),user_id:w},X)}}catch(K){if(f0.warn(`[orm] audit(create) failed for ${Z}`,{error:K}),X)throw K}return U})};let L=$.update;if(typeof L==="function")$.update=async function(V,U){return await G(async()=>{let K=Q.find,T=typeof K==="function"?j0(await K.call(Q,V)):null,w=await L.call(this,V,U);try{let D=j0(w)??(typeof K==="function"?j0(await K.call(Q,V)):null),{old:C,next:E}=mz(T,D);if(E&&Object.keys(E).length>0){let k=await F$();await k$({auditable_type:Z,auditable_id:V,event:"updated",old_values:x8(C),new_values:x8(E),user_id:k},X)}}catch(D){if(f0.warn(`[orm] audit(update) failed for ${Z}#${String(V)}`,{error:D}),X)throw D}return w})};let B=(V)=>{let U=$[V];if(typeof U!=="function")return;$[V]=async function(K){return await G(async()=>{let T=Q.find,w=typeof T==="function"?j0(await T.call(Q,K)):null,D=await U.call(this,K);try{if(D!==!1&&w){let C=await F$();await k$({auditable_type:Z,auditable_id:K,event:"deleted",old_values:x8(w),new_values:null,user_id:C},X)}}catch(C){if(f0.warn(`[orm] audit(${V}) failed for ${Z}#${String(K)}`,{error:C}),X)throw C}return D})}};B("delete"),B("softDelete")}function z4($){let Z=$;return Z?.code==="SQLITE_CONSTRAINT_UNIQUE"||Z?.code==="SQLITE_CONSTRAINT"||Z?.code==="23505"||Z?.errno===1062||/unique|duplicate/i.test(Z?.message??"")}function uz($,Z,J){let Y=$;if($ instanceof Error&&typeof Y.status==="number"&&Number.isInteger(Y.status)&&Y.status>=400&&Y.status<600){let X={error:$.message};if(Y.details!==void 0)X.details=Y.details;return{status:Y.status,body:X}}if(z4($))return{status:409,body:{error:`${Z} already exists`}};return{status:500,body:{error:`Failed to ${J} ${Z}`,detail:String($)}}}import{cacheRequestQuery as cz}from"@stacksjs/router";var A8=new WeakMap;function GF($,Z){return cz(`batchLoad:${$.name??"model"}:${String(Z)}`,async()=>{return new Promise((J,Y)=>{let X=A8.get($);if(!X)X={keys:[],resolvers:[],scheduled:!1},A8.set($,X);if(X.keys.push(Z),X.resolvers.push({key:Z,resolve:J,reject:Y}),X.scheduled)return;X.scheduled=!0,Promise.resolve().then(async()=>{let Q=A8.get($);if(!Q)return;A8.delete($);let G=Array.from(new Set(Q.keys));try{let W=typeof $.findMany==="function"?await $.findMany(G):await Promise.all(G.map((B)=>$.find?.(B))),L=new Map;for(let B of W??[]){let V=B?.id;if(V!==void 0)L.set(V,B)}for(let B of Q.resolvers)B.resolve(L.get(B.key))}catch(W){for(let L of Q.resolvers)L.reject(W)}})})})}import{db as LF}from"@stacksjs/database";class lz{conditions=[];where($,...Z){let[J,Y]=Z,X=Y===void 0?"=":J,Q=Y===void 0?J:Y;this.addCondition("and","where",$,X,Q)}orWhere($,...Z){let[J,Y]=Z,X=Y===void 0?"=":J,Q=Y===void 0?J:Y;this.addCondition("or","where",$,X,Q)}whereIn($,Z){this.conditions.push({type:"and",method:"whereIn",column:$,values:Z})}whereNotIn($,Z){this.conditions.push({type:"and",method:"whereIn",column:$,values:Z,operator:"not in"})}whereNull($){this.conditions.push({type:"and",method:"whereNull",column:$})}whereNotNull($){this.conditions.push({type:"and",method:"whereNotNull",column:$})}whereBetween($,Z){this.conditions.push({type:"and",method:"whereBetween",column:$,range:Z})}whereExists($){this.conditions.push({type:"and",method:"whereExists",column:"",callback:$})}addCondition($,Z,J,Y,X){this.conditions.push({type:$,method:Z,column:J,operator:Y,value:X})}getConditions(){return this.conditions}}import{db as N8,runInTransactionScope as nz}from"@stacksjs/database";async function KF($,Z){return await nz(async()=>{return await N8.transaction($,Z)})}function HF($){return N8.transaction(async()=>{await $()})}async function TF($){return await N8.savepoint($)}function wF($,Z){return N8.transactional($,Z)}import{path as p}from"@stacksjs/path";import{fs as a,globSync as v$}from"@stacksjs/storage";import{plural as D4,singular as K4,snakeCase as j}from"@stacksjs/strings";import{isString as I8}from"@stacksjs/validation";var A$;function O4(){if(!A$)A$=import("@stacksjs/build");return A$}async function FF($){if(typeof $==="string")$=(await import($)).default;return $.table??j(D4($?.name||""))}function _0($,Z){if($.name)return $.name;return p.basename(Z).replace(/\.ts$/,"")}function c($,Z){if($.table)return $.table;return j(D4(_0($,Z)))}function pz($,Z){let J=[$,Z];return J.sort(),J.join("_")}function kF($,Z){return Z in $}async function dz($,Z){let J=[];if($.hasOne)for(let Y of $.hasOne)J.push(await N$(Y,$,Z,"hasOne"));if($.hasMany)for(let Y of $.hasMany)J.push(await N$(Y,$,Z,"hasMany"));if($.belongsTo)for(let Y of $.belongsTo)J.push(await N$(Y,$,Z,"belongsTo"));if($.hasOneThrough)for(let Y of $.hasOneThrough)J.push(await T4(Y,$,Z,"hasOneThrough"));if($.hasManyThrough)for(let Y of $.hasManyThrough)J.push(await T4(Y,$,Z,"hasManyThrough"));if($.belongsToMany)for(let Y of $.belongsToMany)J.push(await az(Y,$,Z,"belongsToMany"));if($.morphOne)J.push(await w4($.morphOne,$,Z,"morphOne"));if($.morphMany){let Y=Array.isArray($.morphMany)?$.morphMany:[$.morphMany];for(let X of Y)J.push(await w4(X,$,Z,"morphMany"))}if($.morphTo){let Y=$.morphTo,X=Array.isArray(Y)?Y:typeof Y==="object"&&Y!==null?[Y]:[];for(let Q of X)J.push(iz(Q,$,Z))}if($.morphToMany){let Y=Array.isArray($.morphToMany)?$.morphToMany:[$.morphToMany];for(let X of Y)J.push(H4(X,$,Z,"morphToMany"))}if($.morphedByMany){let Y=Array.isArray($.morphedByMany)?$.morphedByMany:[$.morphedByMany];for(let X of Y)J.push(H4(X,$,Z,"morphedByMany"))}return J}function iz($,Z,J){let Y=$&&typeof $==="object"&&$.name?String($.name):`${j(J)}able`,X=$?.type||`${Y}_type`;return{relationship:"morphTo",model:"",table:"",relationTable:"",foreignKey:$?.id||`${Y}_id`,modelKey:X,relationName:Y,relationModel:J,throughModel:"",throughForeignKey:"",pivotForeign:"",pivotKey:"",pivotTable:""}}function H4($,Z,J,Y){let X=typeof $==="object"&&$!==null,Q=X?String($.model||""):String($),G=X&&$.morphName?String($.morphName):`${j(J)}able`,W=X&&$.pivotTable?String($.pivotTable):G,L=X&&$.id||`${G}_id`,B=X&&$.type||`${G}_type`;return{relationship:Y,model:Q,table:"",relationTable:"",foreignKey:L,modelKey:B,relationName:G,relationModel:J,throughModel:"",throughForeignKey:"",pivotForeign:L,pivotKey:B,pivotTable:W}}async function P8($,Z){let J=P$(`${Z}.ts`),Y=P$(`${$}.ts`),X=I$(`${$}.ts`),Q=I$(`${Z}.ts`);if(!J&&!Q)throw Error(`Model not found: ${Z}`);if(!Y&&!X)throw Error(`Model not found: ${$}`);let G;try{if(a.existsSync(J))G=(await import(J)).default;else G=(await import(Q)).default}catch(L){throw Error(`Failed to load model: ${Z}. Error: ${L?.message||"Unknown error"}`)}let W=a.existsSync(Y)?Y:X;return{modelRelation:G,modelPath:W,modelRelationPath:a.existsSync(J)?J:Q}}async function T4($,Z,J,Y){let X="",Q="",G="",W="";if(I8($))X=$;else X=$.model,Q=$.relationName||"",G=$.through,W=$.throughForeignKey||"";let{modelRelation:L,modelPath:B,modelRelationPath:V}=await P8(J,X),U=c(L,V),K=c(Z,B),T=j(_0(L,V)),w=j(J);return{relationship:Y,model:X,table:U,relationTable:K,foreignKey:`${w}_id`,modelKey:`${T}_id`,relationName:Q,relationModel:J,throughModel:G,throughForeignKey:W,pivotForeign:`${w}_id`,pivotKey:`${T}_id`,pivotTable:K}}async function az($,Z,J,Y){let X="",Q="",G="",W=j(J);if(I8($))X=$;else X=$.model,Q=$.pivotTable||"",G=$.firstForeignKey||`${W}_id`;let{modelRelation:L,modelPath:B,modelRelationPath:V}=await P8(J,X),U=c(L,V),K=c(Z,B),T=j(_0(L,V));return{relationship:Y,model:X,table:U,relationTable:K,foreignKey:typeof $==="string"?`${W}_id`:$.firstForeignKey||`${W}_id`,modelKey:typeof $==="string"?`${T}_id`:$.secondForeignKey||`${T}_id`,relationName:"",relationModel:J,throughModel:"",throughForeignKey:"",pivotForeign:G,pivotKey:`${T}_id`,pivotTable:Q}}async function w4($,Z,J,Y){let X="",Q="",G="",W="";if(I8($))X=$,Q=`${j(J)}able`;else X=$.model,Q=$.morphName||`${j(J)}able`,G=$.type||`${Q}_type`,W=$.id||`${Q}_id`;let{modelRelation:L,modelPath:B,modelRelationPath:V}=await P8(J,X),U=c(L,V),K=c(Z,B);return{relationship:Y,model:X,table:U,relationTable:K,foreignKey:W||`${Q}_id`,modelKey:G||`${Q}_type`,relationName:Q,relationModel:J,throughModel:"",throughForeignKey:"",pivotForeign:"",pivotKey:"",pivotTable:K}}async function N$($,Z,J,Y){let X="",Q="";if(I8($))X=$;else X=$.model,Q=$.relationName||"";let{modelRelation:G,modelPath:W,modelRelationPath:L}=await P8(J,X),B=c(G,L),V=c(Z,W),U=j(_0(G,L)),K=j(J),T={relationship:Y,model:X,table:B,relationTable:V,foreignKey:typeof $==="string"?`${K}_id`:$.foreignKey||`${K}_id`,modelKey:`${U}_id`,relationName:Q,relationModel:J,throughModel:"",throughForeignKey:"",pivotForeign:`${K}_id`,pivotKey:`${U}_id`,pivotTable:V};if(Y==="belongsTo")T.foreignKey="";return T}function xF($){let Z=/belongs/,J=/has/,Y=/Through/,X=/morph/;if(Y.test($))return"throughType";if(Z.test($))return"belongsType";if(J.test($))return"hasType";if(X.test($))return"morphType";return""}function AF($){let Z=/One/;if(/Many/.test($))return"many";if(Z.test($))return"one";return""}async function NF($,Z){let J=[];if("belongsToMany"in $){let Y=$.belongsToMany||[];for(let X of Y){let Q,G;if(typeof X==="string")G=X;else G=X.model;let W=P$(`${G}.ts`),L=I$(`${G}.ts`);if(a.existsSync(W))Q=(await import(W)).default;else Q=(await import(L)).default;let B=c(Q,W),V=c($,Z),U=typeof X==="object"&&"firstForeignKey"in X?X.firstForeignKey:`${K4(V)}_${$.primaryKey}`,K=typeof X==="object"&&"secondForeignKey"in X?X.secondForeignKey:`${K4(B)}_${$.primaryKey}`;J.push({table:(typeof X==="object"&&"pivotTable"in X?X.pivotTable:void 0)??pz(V,B),firstForeignKey:U,secondForeignKey:K})}return J}return[]}async function IF($){let Z=v$([p.userModelsPath("*.ts"),p.storagePath("framework/defaults/app/Models/**/*.ts")],{absolute:!0}),J=[];for(let Y=0;Y<Z.length;Y++){let X=Z[Y],Q=await import(X);if($===Q.default.name)continue;let G=_0(Q,X),W=await dz(Q.default,G);if(!W.length)continue;let L=W.find((B)=>B.model===$);if(L)J.push(L)}return J}function PF($){if($===void 0)return[];return Object.keys($).filter((Z)=>{return $[Z]?.hidden===!0})}function vF($){let Z=$.attributes;if(Z===void 0)return[];return Object.keys(Z).filter((J)=>{return Z[J]?.guarded===!0}).map((J)=>j(J))}function yF($,Z){let J=$.attributes,Y=[];if(J===void 0)return[];let X=typeof $.traits?.billable==="object"||typeof $.traits?.billable==="boolean",Q=typeof $.traits?.useAuth==="object"?$.traits?.useAuth.usePasskey:!1,G=$.traits?.useUuid||!1;if(X)Y.push("stripe_id");if(G)Y.push("uuid");if(Q)Y.push(...["two_factor_secret","public_key"]);let W=Z.map((L)=>L.foreignKey).filter((L)=>L);return[...Object.keys(J).filter((L)=>{if(J===void 0)return!1;return J[L]?.fillable===!0}).map((L)=>j(L)),...Y,...W]}async function SF($,Z){let J=$.attributes;if(!J)J={};let Y=Object.keys(J),X=[],Q=Bun.file(Z),G="";try{if(await Q.exists())G=await Q.text()}catch{G=""}let W=/rule:.*$/gm,L;L=W.exec(G);while(L!==null)X.push(L[0]),L=W.exec(G);return Y.map((V,U)=>{let K=J[V],T=null,w=!1,D=!1,C=!1,E=!1;if(K)T=K||null,w=K.unique||!1,D=K.hidden||!1,C=K.fillable||!1;let k=X[U]??"";return E=(K.validation?.rule).isRequired??!1,{field:V,default:T,unique:w,hidden:D,fillable:C,required:E,fieldArray:sz(k)}})}function sz($){let Z=$.split("rule: schema.");if(Z.length!==2)return null;if(!Z[1])Z[1]="";let J=Z[1].replace(/,/g,"");if(!J)return null;let Y=J.split("."),X=/\(([^)]+)\)/;return Y.map((Q)=>{let G=X.exec(Q),W=G?G[1]:null;return{entity:Q.replace(X,"").replace(/\(|\)/g,""),charValue:W}})[0]||null}function RF($){let Z=$.fieldArray?.entity;switch(Z){case"enum":return"string | string[]";case"date":return"Date | string";case"timestamp":return"Date | string";case"datetime":return"Date | string";case"float":return"number";case"double":return"number";case"decimal":return"number";case"integer":return"number";case"bigint":return"number";default:return Z}}async function bF($){let{generator:Z,parser:J,traverse:Y}=await O4(),X=a.readFileSync($,"utf8"),Q=J.parse(X,{sourceType:"module",plugins:["typescript","classProperties","decorators-legacy"]}),G=[];return Y(Q,{ImportDeclaration(W){let L=Z(W.node,{},X);G.push(L.code)}}),G}async function jF($){let{generator:Z,parser:J,traverse:Y}=await O4(),X=a.readFileSync($,"utf8"),Q=J.parse(X,{sourceType:"module",plugins:["typescript","classProperties","decorators-legacy"]}),G;return Y(Q,{ObjectExpression(W){let L=W.node.properties.find((B)=>B.type==="ObjectProperty"&&B.key.type==="Identifier"&&B.key.name==="attributes");if(L&&L.type==="ObjectProperty"&&L.value)G=Z(L.value,{},X).code,W.stop()}}),G}function I$($){let Z=p.join(p.storagePath("framework/defaults/app/Models"),"/"),J=p.join(Z,$);if(a.existsSync(J))return J;return v$(`${Z}**/${$}`,{absolute:!0})[0]??""}function P$($){let Z=p.join(p.userModelsPath("/"),"/"),J=p.join(Z,$);if(a.existsSync(J))return J;return v$(`${Z}**/${$}`,{absolute:!0})[0]??""}function fF($){let Z=typeof $==="number"?new Date($):typeof $==="string"?new Date($):$;if(Number.isNaN(Z.getTime()))throw Error(`Invalid date value: ${String($)}`);return Z.toISOString().replace("T"," ").split(".")[0]??""}function _F($){return $.toISOString().split("T")[0]??""}function gF($){return $.getTime()}import{createModel as GE,registerModel as WE}from"@stacksjs/query-builder";import{log as m}from"@stacksjs/logging";import{snakeCase as w$}from"@stacksjs/strings";import{AsyncLocalStorage as VE}from"async_hooks";function oz($){if($===null||typeof $!=="object")return!1;let Z=$;return Array.isArray(Z.data)&&typeof Z.current_page==="number"&&typeof Z.per_page==="number"&&typeof Z.total==="number"&&typeof Z.last_page==="number"}function rz($){if($===null||typeof $!=="object")return!1;let Z=$;return Array.isArray(Z.data)&&typeof Z.current_page==="number"&&typeof Z.per_page==="number"&&typeof Z.has_more_pages==="boolean"&&!("total"in Z)}function tz($){if($===null||typeof $!=="object")return!1;let Z=$;return Array.isArray(Z.data)&&(typeof Z.next_cursor==="string"||Z.next_cursor===null)}function y$($){let{data:Z}=$,{perPage:J,page:Y,total:X,lastPage:Q}=$.meta,G=Z.length===0,W=G?null:(Y-1)*J+1,L=G?null:W+Z.length-1;return{data:Z,current_page:Y,per_page:J,total:X,last_page:Q,from:W,to:L,has_more_pages:Y<Q}}function S$($){return{data:$.data,current_page:$.meta.page,per_page:$.meta.perPage,has_more_pages:$.meta.hasMore}}function R$($){return{data:$.data,per_page:$.meta.perPage,next_cursor:q4($.meta.nextCursor),prev_cursor:q4($.meta.prevCursor),has_more_pages:$.meta.nextCursor!==null&&$.meta.nextCursor!==void 0}}function q4($){if($===null||$===void 0)return null;if(typeof $==="string")return $;return JSON.stringify($)}function j$($,Z){let J=g$(),Y=J?b$(J,"per_page"):void 0,X=J?b$(J,"page"):void 0,Q=$!==void 0?Math.max(1,Math.floor($)):Math.min(100,Math.max(1,Y??15)),G=Math.max(1,Math.floor(Z??X??1));return{perPage:Q,page:G}}function f$($,Z){let J=g$(),Y=J?C4(J,"cursor"):void 0,X=J?b$(J,"per_page"):void 0,Q=$!==void 0?Math.max(1,Math.floor($)):Math.min(100,Math.max(1,X??15)),W=E4(Z!==void 0?Z:Y??null);return{perPage:Q,cursor:W}}function E4($){if($===null||$===void 0)return null;if(Array.isArray($))return $;if(typeof $==="string"&&$.startsWith("["))try{let Z=JSON.parse($);if(Array.isArray(Z))return Z}catch{}return $}function _$($){let Z=g$();if(!Z)return $;let J=(()=>{try{return new URL(Z.url)}catch{return null}})();if(!J)return $;let Y=J.pathname;if($.path=Y,"next_cursor"in $)return $.next_page_url=$.next_cursor!==null?Y0(J,{cursor:$.next_cursor}):null,$.prev_page_url=$.prev_cursor!==null?Y0(J,{cursor:$.prev_cursor}):null,$;let X=$.current_page;if($.prev_page_url=X>1?Y0(J,{page:X-1}):null,"total"in $){let Q=$.last_page;$.next_page_url=X<Q?Y0(J,{page:X+1}):null,$.first_page_url=Y0(J,{page:1}),$.last_page_url=Y0(J,{page:Q})}else $.next_page_url=$.has_more_pages?Y0(J,{page:X+1}):null;return $}function Y0($,Z){let J=new URL($.toString());for(let[Y,X]of Object.entries(Z))J.searchParams.set(Y,String(X));return`${J.pathname}${J.search}`}var w0;function g$(){if(w0===null)return;if(w0===void 0)try{let Z=q("@stacksjs/router");if(typeof Z.getCurrentRequest==="function")w0=Z.getCurrentRequest;else{w0=null;return}}catch{w0=null;return}return w0()}function b$($,Z){let J=C4($,Z);if(J===void 0)return;let Y=Number(J);return Number.isFinite(Y)?Y:void 0}function C4($,Z){let J=$.query?.[Z];if(J===void 0)return;return Array.isArray(J)?J[0]:J}import{db as ez,sql as $K}from"@stacksjs/database";function M$($,Z){if(typeof $!=="number"||!Number.isFinite($)||$<=0)throw Error(`[orm/taggable] ${Z} requires a positive numeric id (received ${String($)})`)}function F4($){let Z=ez;return{async tags(J){return M$(J,"tags"),await Z.selectFrom("taggable").where("taggable_id","=",J).where("taggable_type","=",$).selectAll().execute()},async tagCount(J){M$(J,"tagCount");let Y=await Z.selectFrom("taggable").select($K`count(*) as count`).where("taggable_id","=",J).where("taggable_type","=",$).executeTakeFirst();return Number(Y?.count)||0},async addTag(J,Y){if(M$(J,"addTag"),!Y||typeof Y.name!=="string"||Y.name.trim().length===0)throw Error("[orm/taggable] addTag requires a non-empty tag.name");return await Z.insertInto("taggable").values({...Y,taggable_id:J,taggable_type:$,slug:Y.name.toLowerCase().replace(/[^a-z0-9]+/g,"-"),order:0,is_active:!0,created_at:new Date().toISOString(),updated_at:new Date().toISOString()}).returningAll().executeTakeFirst()},async activeTags(J){return await Z.selectFrom("taggable").where("taggable_id","=",J).where("taggable_type","=",$).where("is_active","=",!0).selectAll().execute()},async inactiveTags(J){return await Z.selectFrom("taggable").where("taggable_id","=",J).where("taggable_type","=",$).where("is_active","=",!1).selectAll().execute()},async removeTag(J,Y){await Z.deleteFrom("taggable").where("taggable_id","=",J).where("taggable_type","=",$).where("id","=",Y).execute()}}}import{db as ZK}from"@stacksjs/database";function k4($){let Z=ZK;async function J(Y){return(await Z.selectFrom("categorizable_models").where("categorizable_id","=",Y).where("categorizable_type","=",$).selectAll().execute()).map((Q)=>Q.category_id)}return{async categories(Y){let X=await J(Y);if(X.length===0)return[];return await Z.selectFrom("categorizable").where("id","in",X).selectAll().execute()},async categoryCount(Y){return(await J(Y)).length},async addCategory(Y,X){let Q=await Z.selectFrom("categorizable").where("name","=",X.name).selectAll().executeTakeFirst();if(!Q)Q=await Z.insertInto("categorizable").values({name:X.name,description:X.description,slug:X.name.toLowerCase().replace(/[^a-z0-9]+/g,"-"),is_active:!0,created_at:new Date().toISOString(),updated_at:new Date().toISOString()}).returningAll().executeTakeFirst();return await Z.insertInto("categorizable_models").values({categorizable_id:Y,categorizable_type:$,category_id:Q.id,created_at:new Date().toISOString(),updated_at:new Date().toISOString()}).returningAll().executeTakeFirst()},async activeCategories(Y){let X=await J(Y);if(X.length===0)return[];return await Z.selectFrom("categorizable").where("id","in",X).where("is_active","=",!0).selectAll().execute()},async inactiveCategories(Y){let X=await J(Y);if(X.length===0)return[];return await Z.selectFrom("categorizable").where("id","in",X).where("is_active","=",!1).selectAll().execute()},async removeCategory(Y,X){await Z.deleteFrom("categorizable_models").where("categorizable_id","=",Y).where("categorizable_type","=",$).where("category_id","=",X).execute()}}}import{db as JK,sql as YK}from"@stacksjs/database";function x4($,Z){if(typeof $!=="number"||!Number.isFinite($)||$<=0)throw Error(`[orm/commentable] ${Z} requires a positive numeric id (received ${String($)})`)}function A4($){let Z=JK;return{async comments(J){return x4(J,"comments"),await Z.selectFrom("comments").where("commentables_id","=",J).where("commentables_type","=",$).selectAll().execute()},async commentCount(J){let Y=await Z.selectFrom("comments").select(YK`count(*) as count`).where("commentables_id","=",J).where("commentables_type","=",$).executeTakeFirst();return Number(Y?.count)||0},async addComment(J,Y){if(x4(J,"addComment"),!Y||typeof Y.title!=="string"||Y.title.trim().length===0)throw Error("[orm/commentable] addComment requires a non-empty comment.title");if(typeof Y.body!=="string"||Y.body.trim().length===0)throw Error("[orm/commentable] addComment requires a non-empty comment.body");return await Z.insertInto("comments").values({...Y,commentables_id:J,commentables_type:$,status:"pending",created_at:new Date().toISOString(),updated_at:new Date().toISOString()}).returningAll().executeTakeFirst()},async approvedComments(J){return await Z.selectFrom("comments").where("commentables_id","=",J).where("commentables_type","=",$).where("status","=","approved").selectAll().execute()},async pendingComments(J){return await Z.selectFrom("comments").where("commentables_id","=",J).where("commentables_type","=",$).where("status","=","pending").selectAll().execute()},async rejectedComments(J){return await Z.selectFrom("comments").where("commentables_id","=",J).where("commentables_type","=",$).where("status","=","rejected").selectAll().execute()}}}import{db as JE}from"@stacksjs/database";function Zz($){let Z=JE;return{async createStripeUser(J,Y){let{manageCustomer:X}=await import("@stacksjs/payments");return await X.createStripeCustomer(J,Y)},async updateStripeUser(J,Y){let{manageCustomer:X}=await import("@stacksjs/payments");return await X.updateStripeCustomer(J,Y)},async deleteStripeUser(J){let{manageCustomer:Y}=await import("@stacksjs/payments");return await Y.deleteStripeUser(J)},async createOrGetStripeUser(J,Y){let{manageCustomer:X}=await import("@stacksjs/payments");return await X.createOrGetStripeUser(J,Y)},async retrieveStripeUser(J){let{manageCustomer:Y}=await import("@stacksjs/payments");return await Y.retrieveStripeUser(J)},async defaultPaymentMethod(J){let{managePaymentMethod:Y}=await import("@stacksjs/payments");return await Y.retrieveDefaultPaymentMethod(J)},async setDefaultPaymentMethod(J,Y){let{managePaymentMethod:X}=await import("@stacksjs/payments");return await X.setDefaultPaymentMethod(J,Y)},async addPaymentMethod(J,Y){let{managePaymentMethod:X}=await import("@stacksjs/payments");return await X.addPaymentMethod(J,Y)},async paymentMethods(J,Y){let{managePaymentMethod:X}=await import("@stacksjs/payments");return await X.listPaymentMethods(J,Y)},async newSubscription(J,Y,X,Q={}){let{manageSubscription:G}=await import("@stacksjs/payments"),W=await G.create(J,Y,X,Q),B=W.latest_invoice?.payment_intent;return{subscription:W,paymentIntent:B}},async updateSubscription(J,Y,X,Q={}){let{manageSubscription:G}=await import("@stacksjs/payments"),W=await G.update(J,Y,X,Q),B=W.latest_invoice?.payment_intent;return{subscription:W,paymentIntent:B}},async cancelSubscription(J,Y,X={}){let{manageSubscription:Q}=await import("@stacksjs/payments");return{subscription:await Q.cancel(Y,X)}},async activeSubscription(J){let{manageSubscription:Y}=await import("@stacksjs/payments"),X=await Z.selectFrom("subscriptions").where("user_id","=",J.id).where("provider_status","=","active").selectAll().executeTakeFirst();if(X){let Q=await Y.retrieve(J,X.provider_id||"");return{subscription:X,providerSubscription:Q}}return},async checkout(J,Y,X={}){let{manageCheckout:Q,manageCustomer:G}=await import("@stacksjs/payments"),W={};if(X.enableTax)W.automatic_tax={enabled:!0},delete X.enableTax;if(X.allowPromotions)W.allow_promotion_codes=!0,delete X.allowPromotions;let V={...{mode:"payment",customer:(await G.createOrGetStripeUser(J,{})).id,line_items:Y.map((U)=>({price:U.priceId,quantity:U.quantity||1}))},...W,...X};return await Q.create(J,V)},async createSetupIntent(J,Y={}){let{manageSetupIntent:X}=await import("@stacksjs/payments");return await X.create(J,Y)},async subscriptionHistory(J){let{manageInvoice:Y}=await import("@stacksjs/payments");return await Y.list(J)},async transactionHistory(J){let{manageTransaction:Y}=await import("@stacksjs/payments");return await Y.list(J)},async connectAccount(J,Y={}){let X=Y.accountColumn||"stripe_account_id",Q=(J._attributes??J)[X];if(!Q)return null;let G=await O8();try{return await G.accounts.retrieve(Q)}catch{return null}},async createConnectAccount(J,Y={}){let X=Y.accountColumn||"stripe_account_id",Q=J._attributes??J,G=Q[X],W=await O8();if(!G){let{stacksIdempotencyKey:L}=await import("@stacksjs/payments"),B=Y.modelTable||$,V=await W.accounts.create({type:Y.type??"express",email:Y.email??Q.email,country:Y.country??"US",capabilities:Y.capabilities??{card_payments:{requested:!0},transfers:{requested:!0}}},{idempotencyKey:L("connect.account.create",B,Q.id)});return G=V.id,await Z.updateTable(B).set({[X]:G}).where("id","=",Number(Q.id)).execute(),V}return await W.accounts.retrieve(G)},async connectOnboardLink(J,Y){let X=Y.accountColumn||"stripe_account_id",G=(J._attributes??J)[X];if(!G)throw Error("connectOnboardLink: model has no Stripe Connect account; call createConnectAccount first");return{url:(await(await O8()).accountLinks.create({account:G,refresh_url:Y.refreshUrl,return_url:Y.returnUrl,type:Y.type??"account_onboarding"})).url,accountId:G}},async syncConnectStatus(J,Y={}){let X=Y.accountColumn||"stripe_account_id",Q=Y.chargesColumn||"charges_enabled",G=Y.payoutsColumn||"payouts_enabled",W=J._attributes??J,L=W[X];if(!L)return{chargesEnabled:!1,payoutsEnabled:!1};let V=await(await O8()).accounts.retrieve(L),U=!!V.charges_enabled,K=!!V.payouts_enabled,T=Y.modelTable||$;return await Z.updateTable(T).set({[Q]:U,[G]:K}).where("id","=",Number(W.id)).execute(),{chargesEnabled:U,payoutsEnabled:K}},async chargeWithSplit(J,Y){let X=await O8(),Q=Y.accountColumn||"stripe_account_id",G=J._attributes??J,W=Y.connectAccountId||G[Q],L={amount:Y.amountCents,currency:Y.currency||"usd",automatic_payment_methods:{enabled:!0},metadata:Y.metadata};if(W){if(L.transfer_data={destination:W},Y.platformFeeCents)L.application_fee_amount=Y.platformFeeCents}let{freshIdempotencyKey:B}=await import("@stacksjs/payments");return await X.paymentIntents.create(L,{idempotencyKey:B("payment_intent.create",G.id,Y.amountCents)})}}}async function O8(){let $=globalThis.process?.env?.STRIPE_SECRET_KEY;if(!$)throw Error("Stripe Connect: STRIPE_SECRET_KEY not configured");return new(await Promise.resolve().then(() => Sz($z(),1))).default($,{apiVersion:"2024-06-20"})}import{db as YE}from"@stacksjs/database";function Jz($,Z){let J=YE,Y=Z?.table||`${$}_likes`,X=Z?.foreignKey||`${$.replace(/s$/,"")}_id`;return{async likes(Q){return await J.selectFrom(Y).where(X,"=",Q).selectAll().execute()},async likeCount(Q){let G=await J.selectFrom(Y).select("count(*) as count").where(X,"=",Q).executeTakeFirst();return Number(G?.count)||0},async like(Q,G){if(typeof Q!=="number"||!Number.isFinite(Q)||Q<=0)throw Error(`[orm/likeable] like requires a positive numeric id (received ${String(Q)})`);if(typeof G!=="number"||!Number.isFinite(G)||G<=0)throw Error(`[orm/likeable] like requires a positive numeric userId (received ${String(G)})`);let W=new Date().toISOString();try{return await J.insertInto(Y).values({[X]:Q,user_id:G,created_at:W,updated_at:W}).returningAll().executeTakeFirst()}catch(L){let B=L;if(!(B.code==="SQLITE_CONSTRAINT_UNIQUE"||B.code==="SQLITE_CONSTRAINT"||B.code==="23505"||B.errno===1062||/unique|duplicate/i.test(B.message??"")))throw L;let U=await J.selectFrom(Y).where(X,"=",Q).where("user_id","=",G).selectAll().executeTakeFirst();if(U)return U;throw L}},async unlike(Q,G){await J.deleteFrom(Y).where(X,"=",Q).where("user_id","=",G).execute()},async isLiked(Q,G){return!!await J.selectFrom(Y).where(X,"=",Q).where("user_id","=",G).selectAll().executeTakeFirst()},async likedBy(Q){return(await J.selectFrom(Y).select([X]).where("user_id","=",Q).execute()).map((W)=>Number(W[X])).filter(Boolean)}}}function Yz(){return{async generateTwoFactorForModel($){let{generateTwoFactorSecret:Z}=await import("@stacksjs/auth"),J=Z();await $.update({two_factor_secret:J})},async verifyTwoFactorCode($,Z){let J=$.get("two_factor_secret");if(typeof J!=="string")return!1;let{verifyTwoFactorCode:Y,RateLimiter:X}=await import("@stacksjs/auth"),Q=String($.id??$.get?.("id")??$.get?.("email")??J),G=`2fa:${Q}`;if(await X.isRateLimited(G)){let{HttpError:L}=await import("@stacksjs/error-handling");throw new L(429,"Too many verification attempts. Please try again later.")}if(!await Y(Z,J))return await X.recordFailedAttempt(G),!1;try{let{cache:L}=await import("@stacksjs/cache"),B=`2fa:used:${Q}:${Z}`;if(await L.has(B))return await X.recordFailedAttempt(G),!1;await L.set(B,"1",90)}catch{}return await X.resetAttempts(G),!0}}}import{log as y0}from"@stacksjs/logging";var H$="deleted_at";function Xz($,Z="id"){return{async softDelete(J){let Y=new Date().toISOString(),X=$.where(Z,J);if(typeof X?.update==="function")return await X.update({[H$]:Y}),!0;return!1},async restore(J){let Y=$.where(Z,J);if(typeof Y?.update==="function")return await Y.update({[H$]:null}),!0;return!1},async forceDelete(J){let Y=$.where(Z,J);if(typeof Y?.delete==="function")return await Y.delete(),!0;return!1},withTrashed(){return typeof $.query==="function"?$.query():$},onlyTrashed(){let J=typeof $.query==="function"?$.query():$;if(typeof J?.whereNotNull==="function")return J.whereNotNull(H$);return J?.where?.(H$,"!=",null)??J}}}function Qz($){if($===!0||$==null)return{};if(typeof $==="object"&&!Array.isArray($)){let Z=$;if(Array.isArray(Z.cascade)){let J=Z.cascade.filter((Y)=>typeof Y==="string");return J.length?{cascade:J}:{}}return{}}return{}}function XE($,Z){let J=$.hasMany??[],Y=$.hasOne??[],X=J.some((V)=>t9(V,Z,!0)),Q=Y.some((V)=>t9(V,Z,!1));if(!X&&!Q)return y0.warn(`[orm] soft-delete cascade: '${Z}' is not a declared hasMany/hasOne relation \u2014 skipping`),null;let W=(X?J:Y).find((V)=>t9(V,Z,X))??null;if(!W)return null;let B=globalThis[W];if(!B)return y0.warn(`[orm] soft-delete cascade: model '${W}' is not yet on globalThis \u2014 skipping cascade for '${Z}'`),null;return{className:W,model:B}}function t9($,Z,J){let Y=$.toLowerCase();if(Z===Y)return!0;if(J&&Z===`${Y}s`)return!0;if(J&&Y.endsWith("y")&&Z===`${Y.slice(0,-1)}ies`)return!0;return!1}async function QE($,Z,J,Y,X){try{let Q=J.where;if(typeof Q!=="function"){y0.warn(`[orm] cascade ${X}: child model has no .where()`);return}if(X==="softDelete"){let G=J.softDelete;if(typeof G==="function"){let L=Q.call(J,Y,Z),B=typeof L?.get==="function"?await L.get():Array.isArray(L)?L:[],V=J.primaryKey||"id";for(let U of B){let K=U?.[V];if(K!=null)await G.call(J,K)}return}let W=Q.call(J,Y,Z);if(typeof W?.delete==="function"){y0.debug(`[orm] cascade soft-delete: child has no softDeletes trait, hard-deleting from ${String(J.table??"?")}`),await W.delete();return}}else{let G=J.restore;if(typeof G!=="function"){y0.debug("[orm] cascade restore: child has no restore() \u2014 nothing to do");return}let W=J.withTrashed,B=(typeof W==="function"?W.call(J):J).where?.(Y,Z),V=typeof B?.get==="function"?await B.get():[],U=J.primaryKey||"id";for(let K of V){let T=K?.[U];if(T!=null)await G.call(J,T)}}}catch(Q){if(y0.warn(`[orm] soft-delete cascade ${X} on ${$}#${String(Z)} failed`,{error:Q}),process.env.STACKS_ORM_CASCADE_SWALLOW!=="true")throw Q}}async function q8($,Z,J,Y){let X=Z.cascade;if(!X||X.length===0)return;let Q=`${$.name.toLowerCase()}_id`;for(let G of X){let W=XE($,G);if(!W)continue;await QE(W.className,J,W.model,Q,Y)}}var Kz=new VE;function K0(){return Kz.getStore()?.suppressed===!0}function z0($){return Promise.resolve(Kz.run({suppressed:!0},$))}var Gz=new Set;function BE($,Z){let J=typeof $==="string"?$.slice(0,80):String($),Y=`${typeof $}:${J}`;if(Gz.has(Y))return;Gz.add(Y);let X=Z instanceof Error?Z.message:String(Z);console.error(`[orm] JSON cast failed to parse value (returning null): ${X} \u2014 value preview: ${JSON.stringify(J)}`)}var LE={string:{get:($)=>$!=null?String($):null,set:($)=>$!=null?String($):null},number:{get:($)=>$!=null?Number($):null,set:($)=>$!=null?Number($):null},integer:{get:($)=>$!=null?Math.trunc(Number($)):null,set:($)=>$!=null?Math.trunc(Number($)):null},float:{get:($)=>$!=null?Number.parseFloat(String($)):null,set:($)=>$!=null?Number.parseFloat(String($)):null},boolean:{get:($)=>$===1||$==="1"||$===!0||$==="true",set:($)=>$===!0||$===1||$==="1"||$==="true"?1:0},json:{get:($)=>{if($==null)return null;if(typeof $==="string")try{return JSON.parse($)}catch(Z){return BE($,Z),null}return $},set:($)=>{if($==null)return null;return typeof $==="string"?$:JSON.stringify($)}},datetime:{get:($)=>$?new Date($):null,set:($)=>$ instanceof Date?$.toISOString():$},date:{get:($)=>$?new Date($):null,set:($)=>$ instanceof Date?$.toISOString().split("T")[0]:$},array:{get:($)=>{if($==null)return[];if(Array.isArray($))return $;if(typeof $==="string")try{return JSON.parse($)}catch{return[]}return[]},set:($)=>{if($==null)return null;return Array.isArray($)?JSON.stringify($):$}}};function Hz($){return typeof $==="string"?LE[$]:$}function Wz($,Z,J){if(!$||typeof $!=="object")return $;let Y={...$};for(let[X,Q]of Object.entries(Z))if(X in Y){let G=Hz(Q);Y[X]=G[J](Y[X])}return Y}var T$=new Set(["_attributes","_original","_definition","_hasSaved","_relations"]),Vz=Symbol.for("stacks.modelInstanceProxy"),UE={tags:{bag:"_taggable",mode:"id"},tagCount:{bag:"_taggable",mode:"id"},addTag:{bag:"_taggable",mode:"id"},activeTags:{bag:"_taggable",mode:"id"},inactiveTags:{bag:"_taggable",mode:"id"},removeTag:{bag:"_taggable",mode:"id"},categories:{bag:"_categorizable",mode:"id"},categoryCount:{bag:"_categorizable",mode:"id"},addCategory:{bag:"_categorizable",mode:"id"},activeCategories:{bag:"_categorizable",mode:"id"},inactiveCategories:{bag:"_categorizable",mode:"id"},removeCategory:{bag:"_categorizable",mode:"id"},comments:{bag:"_commentable",mode:"id"},commentCount:{bag:"_commentable",mode:"id"},addComment:{bag:"_commentable",mode:"id"},approvedComments:{bag:"_commentable",mode:"id"},pendingComments:{bag:"_commentable",mode:"id"},rejectedComments:{bag:"_commentable",mode:"id"},likes:{bag:"_likeable",mode:"id"},likeCount:{bag:"_likeable",mode:"id"},like:{bag:"_likeable",mode:"id"},unlike:{bag:"_likeable",mode:"id"},isLiked:{bag:"_likeable",mode:"id"},createStripeUser:{bag:"_billable",mode:"model"},updateStripeUser:{bag:"_billable",mode:"model"},deleteStripeUser:{bag:"_billable",mode:"model"},createOrGetStripeUser:{bag:"_billable",mode:"model"},retrieveStripeUser:{bag:"_billable",mode:"model"},defaultPaymentMethod:{bag:"_billable",mode:"model"},setDefaultPaymentMethod:{bag:"_billable",mode:"model"},addPaymentMethod:{bag:"_billable",mode:"model"},paymentMethods:{bag:"_billable",mode:"model"},newSubscription:{bag:"_billable",mode:"model"},updateSubscription:{bag:"_billable",mode:"model"},cancelSubscription:{bag:"_billable",mode:"model"},activeSubscription:{bag:"_billable",mode:"model"},checkout:{bag:"_billable",mode:"model"},createSetupIntent:{bag:"_billable",mode:"model"},subscriptionHistory:{bag:"_billable",mode:"model"},transactionHistory:{bag:"_billable",mode:"model"},connectAccount:{bag:"_billable",mode:"model"},createConnectAccount:{bag:"_billable",mode:"model"},connectOnboardLink:{bag:"_billable",mode:"model"},syncConnectStatus:{bag:"_billable",mode:"model"},chargeWithSplit:{bag:"_billable",mode:"model"},generateTwoFactorForModel:{bag:"_twoFactor",mode:"model"},verifyTwoFactorCode:{bag:"_twoFactor",mode:"model"}};function zE($,Z){if(!$||!Z)return null;let J=Z.split("."),Y=$;for(let X of J){if(Y==null||typeof Y!=="object")return null;let Q=Y;if("_attributes"in Q&&Q._attributes&&typeof Q._attributes==="object"){let G=Q._attributes;if(X in G){Y=G[X];continue}}if(X in Q){Y=Q[X];continue}return null}return Y??null}function u($,Z){if(!$||typeof $!=="object")return $;if($[Vz])return $;let J=$._attributes;if(!J||typeof J!=="object")return $;if(Z&&Object.keys(Z).length>0){for(let[Y,X]of Object.entries(Z))if(Object.prototype.hasOwnProperty.call(J,Y))J[Y]=Hz(X).get(J[Y])}return new Proxy($,{get(Y,X,Q){if(X===Vz)return!0;if(X==="saveAsync")return async function(){let W=Y._definition,L=W?.set;if(L&&typeof Y.isDirty==="function"){for(let[V,U]of Object.entries(L)){if(typeof U!=="function")continue;if(!Y.isDirty(V))continue;let K=U(Y._attributes),T=K&&typeof K.then==="function"?await K:K;Y._attributes[V]=T}let B=W.set;W.set={};try{return Y.save()}finally{W.set=B}}return Y.save()};if(X==="save")return function(){let W=Y._definition,L=W?.set;if(L&&Object.keys(L).length>0&&typeof Y.isDirty==="function"){for(let[V,U]of Object.entries(L)){if(typeof U!=="function")continue;if(!Y.isDirty(V))continue;let K=U(Y._attributes);if(K&&typeof K.then==="function")throw Error(`Setter for "${V}" returned a Promise \u2014 use \`saveAsync()\` instead of \`save()\` when a model has async setters.`);Y._attributes[V]=K}let B=W.set;W.set={};try{return Y.save()}finally{W.set=B}}return Y.save()};if(X==="updateAsync")return async function(W){if(W&&typeof W==="object"&&!Array.isArray(W))for(let[L,B]of Object.entries(W))Q[L]=B;return Q.saveAsync()};if(X==="saveQuietly")return function(){return z0(()=>Y.save())};if(X==="saveAsyncQuietly")return function(){return z0(()=>Q.saveAsync())};if(X==="updateQuietly")return function(W){return z0(()=>Y.update(W))};if(X==="updateAsyncQuietly")return function(W){return z0(()=>Q.updateAsync(W))};if(X==="deleteQuietly")return function(){return z0(()=>Y.delete())};if(X==="toSearchableObject")return function(){let B=Y._definition?.traits?.useSearch;if(!B)return null;let V=Y._attributes;if(!V)return null;if(B===!0){let D={...V};if(V.id!=null)D.id=String(V.id);return D}let U={},K=B.displayable?.length?B.displayable:[...B.searchable??[],...B.filterable??[],...B.sortable??[],"id"],T=B.denormalize??{},w=Y._relations;for(let D of K){let C=w$(D),E=V[C]??V[D];if(E!==void 0){U[C]=E;continue}let k=T[D]??T[C];if(k){U[C]=zE(w,k);continue}U[C]=void 0}if(V.id!=null)U.id=String(V.id);return U};if(typeof X==="string"&&!T$.has(X)){let W=Y._attributes;if(W&&Object.prototype.hasOwnProperty.call(W,X))return W[X];let L=Y._relations;if(L&&Object.prototype.hasOwnProperty.call(L,X)){let V=L[X];if(Array.isArray(V))return V.map((U)=>u(U,Z));return u(V,Z)}let B=UE[X];if(B){let K=Y._definition?.__traitMethods?.[B.bag]?.[X];if(typeof K==="function")return B.mode==="model"?(...T)=>K(Q,...T):(...T)=>K(Y.id,...T)}}let G=Reflect.get(Y,X,Y);return typeof G==="function"?G.bind(Y):G},set(Y,X,Q,G){if(typeof X==="string"&&!T$.has(X)){let{_attributes:W,set:L}=Y;if(W&&Object.prototype.hasOwnProperty.call(W,X)){if(typeof L==="function")L.call(Y,X,Q);else W[X]=Q;return!0}if(W&&!(X in Y)){if(typeof L==="function")L.call(Y,X,Q);else W[X]=Q;return!0}}return Reflect.set(Y,X,Q,G)},has(Y,X){if(typeof X==="string"&&!T$.has(X)){let Q=Y._attributes;if(Q&&Object.prototype.hasOwnProperty.call(Q,X))return!0;let G=Y._relations;if(G&&Object.prototype.hasOwnProperty.call(G,X))return!0}return Reflect.has(Y,X)},deleteProperty(Y,X){if(typeof X==="string"&&!T$.has(X)){let Q=Y._attributes;if(Q&&Object.prototype.hasOwnProperty.call(Q,X))return delete Q[X],!0}return Reflect.deleteProperty(Y,X)},ownKeys(Y){let X=Y._attributes;return X?Object.keys(X):[]},getOwnPropertyDescriptor(Y,X){if(typeof X==="string"){let Q=Y._attributes;if(Q&&Object.prototype.hasOwnProperty.call(Q,X))return{configurable:!0,enumerable:!0,value:Q[X],writable:!0}}return Object.getOwnPropertyDescriptor(Y,X)}})}var KE=new Set(["get","first","last","firstOrFail","find","findOrFail","all","paginate","simplePaginate","cursorPaginate"]),HE={paginate:y$,simplePaginate:S$,cursorPaginate:R$},Bz=Symbol.for("stacks.queryBuilderProxy");function Tz($,Z){if(!$||typeof $!=="object")return $;if($[Bz])return $;return new Proxy($,{get(J,Y,X){if(Y===Bz)return!0;let Q=Reflect.get(J,Y,X);if(typeof Q!=="function")return Q;return function(...G){let W=G,L=String(Y);if(L==="paginate"||L==="simplePaginate"){let{perPage:U,page:K}=j$(G[0],G[1]);W=[U,K]}else if(L==="cursorPaginate"){let{perPage:U,cursor:K}=f$(G[0],G[1]);W=[U,K,G[2],G[3]]}let B=Q.apply(J,W),V=(U)=>{if(KE.has(L)){if(Array.isArray(U))return U.map((T)=>u(T,Z));let K=HE[L];if(K&&U&&Array.isArray(U.data)){let T=U.data.map((D)=>u(D,Z)),w=K({...U,data:T});return _$(w)}if(U&&Array.isArray(U.data))return{...U,data:U.data.map((T)=>u(T,Z))};return u(U,Z)}if(U&&typeof U==="object"&&typeof U.get==="function")return Tz(U,Z);return U};if(B&&typeof B.then==="function")return B.then(V);return V(B)}}})}function TE($,Z){let J=["find","first","last","all","firstOrFail","findOrFail","findMany"];for(let Q of J){let G=$[Q];if(typeof G!=="function")continue;$[Q]=function(...W){let L=G.apply(this,W),B=(V)=>Array.isArray(V)?V.map((U)=>u(U,Z)):u(V,Z);if(L&&typeof L.then==="function")return L.then(B);return B(L)}}let Y=["create","firstOrCreate","updateOrCreate","make"];for(let Q of Y){let G=$[Q];if(typeof G!=="function")continue;$[Q]=function(...W){let L=G.apply(this,W),B=(V)=>Array.isArray(V)?V.map((U)=>u(U,Z)):u(V,Z);if(L&&typeof L.then==="function")return L.then(B);return B(L)}}let X=["query","where","orWhere","whereIn","whereNotIn","whereNull","whereNotNull","whereLike","whereBetween","whereNotBetween","orderBy","orderByDesc","select","with","limit","take","skip","latest","oldest"];for(let Q of X){let G=$[Q];if(typeof G!=="function")continue;$[Q]=function(...W){let L=G.apply(this,W);return Tz(L,Z)}}}class wz extends Error{model;id;constructor($,Z){super(Z!=null?`[ORM] ${$} not found for id=${String(Z)}`:`[ORM] No matching ${$} row`);this.name="ModelNotFoundError",this.model=$,this.id=Z}}class $4 extends Error{model;attribute;reason;constructor($,Z,J){let Y=J==="guarded"?`'${Z}' is marked guarded`:`'${Z}' is not in the fillable allowlist`;super(`[ORM] Mass assignment to ${$} forbidden: ${Y}. Use ${$}.forceCreate(...) / .forceUpdate(...) to bypass.`);this.name="MassAssignmentException",this.model=$,this.attribute=Z,this.reason=J}}var wE=new Set(["id","created_at","updated_at","deleted_at","uuid"]);function E8($,Z,J={}){if(J.force)return Z;if(!Z||typeof Z!=="object"||Array.isArray(Z))return Z;let Y=$.attributes;if(!Y)return Z;let X=new Set,Q=new Set,G=new Set;for(let[L,B]of Object.entries(Y)){let V=w$(L);if(X.add(V),B?.fillable===!0)Q.add(V);if(B?.guarded===!0)G.add(V)}let W=Q.size>0?Q:X;for(let L of Object.keys(Z)){if(wE.has(L))continue;if(G.has(L))throw new $4($.name,L,"guarded");if(L.endsWith("_id"))continue;if(!W.has(L))throw new $4($.name,L,"not-fillable")}return Z}async function Z4($,Z){let J=$.set;if(!J||typeof J!=="object")return Z;let Y={...Z};for(let[X,Q]of Object.entries(J)){if(typeof Q!=="function"||!(X in Y))continue;try{Y[X]=await Q(Y)}catch(G){m.error(`[orm] ${$.name}.set.${X} threw \u2014 skipping setter`,G)}}return Y}function DE($,Z){let J=Z.primaryKey||"id",Y=$.create;function X(B){let V=$.where;if(typeof V!=="function")throw Error(`[ORM] ${Z.name}.${B} needs a working where(): the underlying query builder did not expose one`);return V}function Q(B){let V=$.find;if(typeof V!=="function")throw Error(`[ORM] ${Z.name}.${B} needs a working find(): the underlying query builder did not expose one`);return V}function G(B){let V=$.create;if(typeof V!=="function")throw Error(`[ORM] ${Z.name}.${B} cannot create: the underlying query builder did not expose create()`);return V}if(typeof $.update!=="function")$.update=async function(B,V){if(B==null)throw Error(`[ORM] ${Z.name}.update requires an id as the first argument`);if(!V||typeof V!=="object"||Array.isArray(V))throw Error(`[ORM] ${Z.name}.update requires a data object as the second argument`);if(Object.keys(V).length===0){m.debug(`[orm] ${Z.name}.update called with empty data \u2014 short-circuiting and returning current row`);let T=$.find;return typeof T==="function"?await T.call($,B):null}E8(Z,V);let U=await Z4(Z,V);await X("update").call($,J,B).update(U);let K=$.find;return typeof K==="function"?await K.call($,B):null};if(typeof $.forceUpdate!=="function")$.forceUpdate=async function(B,V){if(B==null)throw Error(`[ORM] ${Z.name}.forceUpdate requires an id as the first argument`);if(!V||typeof V!=="object"||Array.isArray(V))throw Error(`[ORM] ${Z.name}.forceUpdate requires a data object as the second argument`);let U=await Z4(Z,V);await X("forceUpdate").call($,J,B).update(U);let K=$.find;return typeof K==="function"?await K.call($,B):null};if(typeof $.forceCreate!=="function")$.forceCreate=async function(B){if(!B||typeof B!=="object"||Array.isArray(B))throw Error(`[ORM] ${Z.name}.forceCreate requires a data object`);if(typeof Y!=="function")throw Error(`[ORM] ${Z.name}.forceCreate cannot create: the underlying query builder did not expose create()`);return await Y.call($,B)};if(typeof $.delete!=="function")$.delete=async function(B){if(B==null)throw Error(`[ORM] ${Z.name}.delete requires an id as the first argument`);if(!await Q("delete").call($,B))return!1;return await X("delete").call($,J,B).delete(),!0};if(typeof $.findOrFail!=="function")$.findOrFail=async function(B){let V=await Q("findOrFail").call($,B);if(V==null)throw new wz(Z.name,B);return V};if(typeof $.exists!=="function")$.exists=async function(B){if(B==null)return!1;let V=X("exists").call($,J,B);if(typeof V.count==="function"){let K=await V.count();return Number(K)>0}let U=$.find;return typeof U==="function"?await U.call($,B)!=null:!1};if(typeof $.firstOrCreate!=="function")$.firstOrCreate=async function(B,V={}){if(!B||typeof B!=="object"||Array.isArray(B))throw Error(`[ORM] ${Z.name}.firstOrCreate requires a where-attrs object`);let U=X("firstOrCreate").call($,B),K=typeof U.first==="function"?await U.first():await U;if(K)return K;let T={...B,...V};return E8(Z,T),await G("firstOrCreate").call($,T)};if(typeof $.updateOrCreate!=="function")$.updateOrCreate=async function(B,V){if(!B||typeof B!=="object"||Array.isArray(B))throw Error(`[ORM] ${Z.name}.updateOrCreate requires a where-attrs object`);if(!V||typeof V!=="object"||Array.isArray(V))throw Error(`[ORM] ${Z.name}.updateOrCreate requires a values object`);let U=X("updateOrCreate").call($,B),K=typeof U.first==="function"?await U.first():await U;if(K){E8(Z,V);let w=K[J];await X("updateOrCreate").call($,J,w).update(V);let D=$.find;return typeof D==="function"?await D.call($,w):{...K,...V}}let T={...B,...V};return E8(Z,T),await G("updateOrCreate").call($,T)};if(typeof $.count!=="function")$.count=async function(){let B=$;if(typeof B.query==="function"){let K=B.query();if(typeof K?.count==="function"){let T=await K.count();return Number(T)||0}}let{all:V,get:U}=$;if(typeof V==="function")return(await V.call($)||[]).length;if(typeof U==="function")return(await U.call($)||[]).length;return 0};if(typeof $.pluck!=="function")$.pluck=async function(B){if(!B||typeof B!=="string")throw Error(`[ORM] ${Z.name}.pluck requires a column name`);let V=$.all;return((typeof V==="function"?await V.call($):[])||[]).map((K)=>K?.[B])};if(typeof $.whereIn!=="function")$.whereIn=async function(B,V){if(!B||typeof B!=="string")throw Error(`[ORM] ${Z.name}.whereIn requires a column name`);if(!Array.isArray(V))throw Error(`[ORM] ${Z.name}.whereIn requires an array of values`);if(V.length===0)return[];let U=$.where;if(typeof U!=="function")return[];let K=U.call($,B,"in",V);if(K&&typeof K.get==="function")return await K.get();return await K};let W=[["latest","desc"],["oldest","asc"]];for(let[B,V]of W)if(typeof $[B]!=="function")$[B]=async function(U="created_at"){let K=$,T=typeof K.query==="function"?K.query():K;if(typeof T?.orderBy==="function"){let E=T.orderBy(U,V);if(typeof E.first==="function")return await E.first();if(typeof E.get==="function")return(await E.get())?.[0]??null}let w=$.all;if(typeof w!=="function")return null;return[...await w.call($)||[]].sort((E,k)=>{let I=E?.[U],R=k?.[U];if(I===R)return 0;return(I>R?1:-1)*(V==="desc"?-1:1)})[0]??null};let L=Dz(Z.traits?.useSearch);if(L){let B=L.index??Z.table??w$(`${Z.name}s`);if(typeof $.search!=="function")$.search=function(V,U){return OE($,B,V,U)};if(typeof $.makeAllSearchable!=="function")$.makeAllSearchable=async function(V=500){let U=$.all;if(typeof U!=="function")throw Error(`[ORM] ${Z.name}.makeAllSearchable cannot run: the underlying query builder did not expose all()`);let{useSearchEngine:K}=await import("@stacksjs/search-engine"),T=K(),w=0,D=$.query;if(typeof D==="function")try{let k=D.call($);if(k&&typeof k.chunk==="function")return await k.chunk(V,async(I)=>{let R=I.map((M)=>Lz(M,L)).filter(Boolean);if(R.length>0)await T.addDocuments(B,R);w+=R.length}),w}catch{}let E=(await U.call($)||[]).map((k)=>Lz(k,L)).filter(Boolean);if(E.length>0)await T.addDocuments(B,E);return E.length};if(typeof $.removeAllFromSearch!=="function")$.removeAllFromSearch=async function(){let{useSearchEngine:V}=await import("@stacksjs/search-engine"),U=V();if(typeof U.deleteAllDocuments==="function"){await U.deleteAllDocuments(B);return}let K=$.all,T=typeof K==="function"?await K.call($)||[]:[],w=V();for(let D of T){let C=D?.id??D?._attributes?.id;if(C!=null)await w.deleteDocument(B,Number(C))}}}}function Lz($,Z){if(typeof Z.shape==="function")try{return Z.shape($)}catch{return}let J=$?.toSearchableObject?.();if(J!==void 0)return J;return $?._attributes??(typeof $?.toJSON==="function"?$.toJSON():null)}function OE($,Z,J,Y){let X={q:J,...Y??{}},Q={with(G){return X={...X,...G},Q},where(G){return X={...X,filter:G},Q},async get(){let{useSearchEngine:G}=await import("@stacksjs/search-engine");return(await G().search(Z,X))?.hits??[]},async paginate(G,W=1){let{useSearchEngine:L}=await import("@stacksjs/search-engine"),V=await L().search(Z,{...X,limit:G,offset:(W-1)*G});return{hits:V.hits??[],total:Number(V.estimatedTotalHits??V.nbHits??V.total??0),page:W,perPage:G}},async raw(){let{useSearchEngine:G}=await import("@stacksjs/search-engine");return await G().search(Z,X)}};return Q}async function e9($,Z){if(!$||typeof $!=="object")return;let J=$._attributes??$;for(let Y of Z){if(!(Y in J))continue;let X=J[Y];if(!b0(X))continue;J[Y]=await E$(X)}}function qE($,Z){if(Z.length===0)return;let J=async(G)=>{if(Array.isArray(G)){for(let W of G)await e9(W,Z);return G}if(G&&typeof G==="object"&&Array.isArray(G.data)){for(let W of G.data)await e9(W,Z);return G}if(G)await e9(G,Z);return G},Y=["find","first","last","all","firstOrFail","findOrFail","findMany"];for(let G of Y){let W=$[G];if(typeof W!=="function")continue;$[G]=async function(...L){let B=await W.apply(this,L);return await J(B)}}let X=["create","firstOrCreate","updateOrCreate","make"];for(let G of X){let W=$[G];if(typeof W!=="function")continue;$[G]=async function(...L){let B=await W.apply(this,L);return await J(B)}}let Q=$.update;if(typeof Q==="function")$.update=async function(G,W){let L=await Q.call(this,G,W);return await J(L)}}function EE($,Z){if(Z.length===0)return;let J=async(Q)=>{if(!Q||typeof Q!=="object"||Array.isArray(Q))return Q;let G={...Q};for(let W of Z)if(W in G)G[W]=await q$(G[W]);return G},Y=["create","firstOrCreate","updateOrCreate"];for(let Q of Y){let G=$[Q];if(typeof G!=="function")continue;$[Q]=async function(...W){if(W[0]=await J(W[0]),W[1])W[1]=await J(W[1]);return await G.apply(this,W)}}let X=$.update;if(typeof X==="function")$.update=async function(Q,G){let W=await J(G);return await X.call(this,Q,W)}}function CE($,Z){let J=$.create;if(typeof J==="function")$.create=async function(Y,...X){E8(Z,Y);let Q=await Z4(Z,Y);return await J.call(this,Q,...X)};for(let Y of["firstOrCreate","updateOrCreate"]){let X=$[Y];if(typeof X!=="function")continue}}function FE($,Z){let J=["create","firstOrCreate","updateOrCreate"];for(let X of J){let Q=$[X];if(typeof Q==="function")$[X]=async function(...G){if(m.debug(`[orm] ${X.charAt(0).toUpperCase()+X.slice(1)} ${String($.name||"unknown")}`,G[0]),G[0]&&typeof G[0]==="object"&&!Array.isArray(G[0]))G[0]=Wz(G[0],Z,"set");return await Q.apply(this,G)}}let Y=$.update;if(typeof Y==="function")$.update=async function(X,Q){let G=Q&&typeof Q==="object"&&!Array.isArray(Q)?Wz(Q,Z,"set"):Q;return await Y.call(this,X,G)}}function HI($){m.debug(`[orm] Defining model: ${$.name} (table: ${$.table})`);let Z=kE($),J=AE($),Y=xE(Z,J),X=NE($);$.__traitMethods=X;let Q=Y?{...$,hooks:{...$.hooks,...Y}}:$,G=GE(Q);if(TE(G,$.casts),DE(G,Q),CE(G,Q),$.casts&&Object.keys($.casts).length>0)FE(G,$.casts);let W=C$($);if(W.length>0)EE(G,W),qE(G,W);let L=$.traits?.useSoftDeletes;if(L)IE(G,Q,L);let B=$.traits?.useAudit;if(B){let U=L4(B);U4(G,$.name,$.primaryKey||"id",U)}G.withoutEvents=function(U){return z0(U)};for(let U of["create","update","firstOrCreate","updateOrCreate","forceCreate","forceUpdate","delete","forceDelete","softDelete","restore"]){let K=G[U];if(typeof K!=="function")continue;let T=`${U}Quietly`;if(typeof G[T]==="function")continue;G[T]=function(...w){return z0(()=>K.apply(G,w))}}let V=Object.assign(G,X,{...$,getDefinition:()=>$,_isStacksModel:!0});return WE($.name,V),V}function kE($){let Z=$.traits?.observe;if(!Z)return;let J=$.name.toLowerCase(),Y=(K)=>{let T=K?.attributes;if(!T||typeof T!=="object")return K;let w=$.primaryKey||"id",D={...T};if(D[w]===void 0&&K[w]!==void 0)D[w]=K[w];return D},X=async(K,T)=>{if(K0())return;try{let{dispatch:w}=await import("@stacksjs/events");await w(K,T)}catch(w){if(w&&typeof w==="object"&&"code"in w&&w.code==="MODULE_NOT_FOUND")return;if(console.error(`[ORM] Event '${K}' handler error:`,w),process.env.STACKS_ORM_EVENT_ERRORS!=="swallow")throw w}},Q=$.traits?.broadcastOn,G=$.traits?.broadcastWith,W=typeof Q==="function"&&typeof G==="function",L=async(K,T)=>{if(!W)return;if(K0())return;try{let w=Q(T),D=Array.isArray(w)?w:[w],C=G(T),k=(await import("@stacksjs/realtime").catch(()=>null))?.broadcast;if(typeof k!=="function")return;for(let I of D){if(typeof I!=="string"||I.length===0)continue;await k(I,K,C)}}catch(w){if(w&&typeof w==="object"&&"code"in w&&w.code==="MODULE_NOT_FOUND")return;if(console.error(`[ORM] Broadcast '${K}' handler error:`,w),process.env.STACKS_ORM_BROADCAST_ERRORS==="throw")throw w}},B=async(K,T)=>{if(K0())return!0;try{let{dispatchAsync:w}=await import("@stacksjs/events"),D=await w(K,T);if(Array.isArray(D)&&D.some((C)=>C===!1))return!1}catch(w){if(w&&typeof w==="object"&&"code"in w&&w.code==="MODULE_NOT_FOUND")return!0;if(console.error(`[ORM] Before-event '${K}' handler error:`,w),process.env.STACKS_ORM_EVENT_ERRORS!=="swallow")throw w}return!0},V=Z===!0?["create","update","delete"]:Array.isArray(Z)?Z:[],U={};if(V.includes("create"))U.beforeCreate=async(K)=>{if(m.debug(`[orm] Create ${J}`,K),!await B(`${J}:saving`,K))throw Error(`[ORM] ${J}:saving event cancelled the operation`);if(!await B(`${J}:creating`,K))throw Error(`[ORM] ${J}:creating event cancelled the operation`)},U.afterCreate=async(K)=>{let T=Y(K);await X(`${J}:created`,T),await X(`${J}:saved`,T),await L(`${J}:created`,K)};if(V.includes("update"))U.beforeUpdate=async(K)=>{if(m.debug(`[orm] Update ${J}#${K?.id??"unknown"}`,K),!await B(`${J}:saving`,K))throw Error(`[ORM] ${J}:saving event cancelled the operation`);if(!await B(`${J}:updating`,K))throw Error(`[ORM] ${J}:updating event cancelled the operation`)},U.afterUpdate=async(K)=>{let T=Y(K);await X(`${J}:updated`,T),await X(`${J}:saved`,T),await L(`${J}:updated`,K)};if(V.includes("delete"))U.beforeDelete=async(K)=>{if(m.debug(`[orm] Delete ${J}#${K?.id??"unknown"}`),!await B(`${J}:deleting`,K))throw Error(`[ORM] ${J}:deleting event cancelled the operation`)},U.afterDelete=async(K)=>{await X(`${J}:deleted`,Y(K)),await L(`${J}:deleted`,K)};return U}function xE(...$){let Z={},J=new Set;for(let Y of $){if(!Y)continue;for(let X of Object.keys(Y))J.add(X)}for(let Y of J){let X=$.map((Q)=>Q?.[Y]).filter((Q)=>typeof Q==="function");if(!X.length)continue;Z[Y]=async(...Q)=>{for(let G of X)await G(...Q)}}return Object.keys(Z).length?Z:void 0}function Dz($){if(!$)return null;if($===!0)return{};if(typeof $==="object")return $;return null}function AE($){let Z=Dz($.traits?.useSearch);if(!Z)return;let J=Z.index??$.table??w$(`${$.name}s`);function Y(G){if(typeof Z.shape==="function")try{return Z.shape(G)}catch(B){m.warn(`[orm/search] shape() threw for ${$.name}: ${B.message}`);return}let L=u(G).toSearchableObject?.();if(L!==void 0)return L;return G?._attributes??(typeof G?.toJSON==="function"?G.toJSON():null)}let X=async(G)=>{if(K0())return;let W=Y(G);if(!W)return;if(Z.queueable){try{let{Jobs:L}=await import("@stacksjs/queue");await L.dispatch("SyncSearchIndex",{index:J,op:"upsert",doc:W})}catch(L){m.warn(`[orm/search] queue dispatch failed for ${$.name}; falling back to inline: ${L.message}`),await Uz(J,W,$.name)}return}await Uz(J,W,$.name)};return{afterCreate:X,afterUpdate:X,afterDelete:async(G)=>{if(K0())return;let W=G?.id??G?._attributes?.id;if(W==null)return;if(Z.queueable){try{let{Jobs:L}=await import("@stacksjs/queue");await L.dispatch("SyncSearchIndex",{index:J,op:"delete",id:Number(W)})}catch(L){m.warn(`[orm/search] queue dispatch failed for ${$.name}#${W}; falling back to inline: ${L.message}`),await zz(J,Number(W),$.name)}return}await zz(J,Number(W),$.name)}}}async function Uz($,Z,J){try{let{useSearchEngine:Y}=await import("@stacksjs/search-engine");await Y().addDocument($,Z)}catch(Y){m.warn(`[orm/search] Failed to index ${J}: ${Y.message}`)}}async function zz($,Z,J){try{let{useSearchEngine:Y}=await import("@stacksjs/search-engine");await Y().deleteDocument($,Z)}catch(Y){m.warn(`[orm/search] Failed to remove ${J}#${Z}: ${Y.message}`)}}function NE($){let Z={},J=$.table,Y=$.traits;if(!Y)return Z;if(Y.taggable)Z._taggable=F4(J);if(Y.categorizable)Z._categorizable=k4(J);if(Y.commentable)Z._commentable=A4(J);if(Y.billable)Z._billable=Zz(J);if(Y.likeable){let Q=typeof Y.likeable==="object"?Y.likeable:void 0;Z._likeable=Jz(J,Q)}let X=Y.useAuth||Y.authenticatable;if(typeof X==="object"&&X&&"useTwoFactor"in X&&X.useTwoFactor)Z._twoFactor=Yz();return Z}function IE($,Z,J){let Y=Xz($,Z.primaryKey||"id"),X=Qz(J),Q=Z,G=Z.name.toLowerCase(),W=Z.traits?.observe!=null&&Z.traits?.observe!==!1,L=async(T)=>{if(!W||K0())return!0;try{let{dispatchAsync:w}=await import("@stacksjs/events"),D=await w(`${G}:restoring`,{id:T});if(Array.isArray(D)&&D.some((C)=>C===!1))return!1}catch(w){if(w?.code!=="MODULE_NOT_FOUND")console.error(`[ORM] Before-event '${G}:restoring' handler error:`,w)}return!0},B=async(T)=>{if(!W||K0())return;try{let{dispatch:w}=await import("@stacksjs/events");await w(`${G}:restored`,{id:T})}catch(w){if(w?.code!=="MODULE_NOT_FOUND")console.error(`[ORM] Event '${G}:restored' handler error:`,w)}},V=process.env.STACKS_ORM_CASCADE_SWALLOW!=="true",U=async(T)=>{if(!X.cascade?.length||!V){let D=await Y.softDelete(T);if(D&&X.cascade?.length)await q8(Q,X,T,"softDelete");return D}let{db:w}=await import("@stacksjs/database");return await w.transaction(async()=>{let D=await Y.softDelete(T);if(D)await q8(Q,X,T,"softDelete");return D})},K=async(T)=>{if(!await L(T))return!1;if(!X.cascade?.length||!V){let E=await Y.restore(T);if(E){if(X.cascade?.length)await q8(Q,X,T,"restore");await B(T)}return E}let{db:D}=await import("@stacksjs/database"),C=await D.transaction(async()=>{let E=await Y.restore(T);if(E)await q8(Q,X,T,"restore");return E});if(C)await B(T);return C};$.softDelete=U,$.restore=K,$.forceDelete=Y.forceDelete,$.withTrashed=Y.withTrashed,$.onlyTrashed=Y.onlyTrashed,$.delete=U}function PE($){if($==null)return $;if(Array.isArray($))return $.map(PE);if(typeof $!=="object")return $;if(typeof $.toJSON==="function")return $.toJSON();if($._attributes&&typeof $._attributes==="object")return $._attributes;return $}import{log as vE}from"@stacksjs/logging";import{path as H0}from"@stacksjs/path";import{fs as C8}from"@stacksjs/storage";function T0($){return $.replace(/([A-Z]+)([A-Z][a-z])/g,"$1_$2").replace(/([a-z\d])([A-Z])/g,"$1_$2").replace(/(\d)([A-Za-z])/g,"$1_$2").toLowerCase()}function yE($){let Z=typeof $.type==="string"?$.type.toLowerCase():"",J=(()=>{switch(Z){case"string":case"text":case"longtext":case"mediumtext":case"tinytext":case"char":case"varchar":case"enum":case"uuid":case"date":case"datetime":case"timestamp":case"timestamptz":case"time":case"year":return"string";case"integer":case"int":case"tinyint":case"smallint":case"mediumint":case"float":case"double":case"decimal":case"numeric":return"number";case"bigint":return"number | bigint";case"boolean":case"bool":return"boolean";case"json":case"jsonb":return"unknown";case"binary":case"blob":case"bytea":return"Uint8Array";default:return"unknown"}})();return $.nullable===!0?`${J} | null`:J}function SE($){let Z={},J=$.belongsTo;if(!J)return Z;let Y=Array.isArray(J)?J:Object.keys(J);for(let X of Y)Z[`${T0(X)}_id`]="number";return Z}function RE($,Z){let[J,Y]=[T0($),T0(Z)].sort();return`${J}_${Y}`}function bE($,Z){let J=Z.belongsToMany;if(!J)return[];let Y=[],X=Array.isArray(J)?J:[];for(let Q of X){let G,W,L,B;if(typeof Q==="string")G=Q;else if(Q&&typeof Q==="object"&&"model"in Q){let T=Q;G=T.model,W=T.pivotTable,L=T.firstForeignKey,B=T.secondForeignKey}else continue;let V=W??RE($,G),U=L??`${T0($)}_id`,K=B??`${T0(G)}_id`;Y.push({table:V,columns:{id:"number",[U]:"number",[K]:"number",created_at:"string",updated_at:"string | null"}})}return Y}function jE($){let Z={id:"number"},J=$.traits??{};if(J.useUuid)Z.uuid="string";if((J.useTimestamps??J.timestampable)!==!1)Z.created_at="string",Z.updated_at="string | null";if(J.useSoftDeletes??J.softDeletable)Z.deleted_at="string | null";return Z}function fE($){let Z={},J=$.attributes??{};for(let[Y,X]of Object.entries(J))Z[T0(Y)]=yE(X);return Z}function Oz($,Z){let J=Object.entries(Z).map(([Y,X])=>` ${Y}: ${X}`).join(`
10
+ `+N+`
11
+ `+R})}let M=Math.floor((typeof O==="number"?O:Date.now())/1000)-L.timestamp;if(T>0&&M>T)throw new o.StripeSignatureVerificationError(z,B,{message:"Timestamp outside the tolerance zone"});return!0}function G(B,z){if(typeof B!=="string")return null;return B.split(",").reduce((L,H)=>{let T=H.split("=");if(T[0]==="t")L.timestamp=parseInt(T[1],10);if(T[0]===z)L.signatures.push(T[1]);return L},{timestamp:-1,signatures:[]})}let V=null;function U(){if(!V)V=$.createDefaultCryptoProvider();return V}function W(B){if(!B)throw new o.StripeError({message:"Options are required"});let z=Math.floor(B.timestamp)||Math.floor(Date.now()/1000),L=B.scheme||J.EXPECTED_SCHEME,H=B.cryptoProvider||U(),T=`${z}.${B.payload}`;return{...B,timestamp:z,scheme:L,cryptoProvider:H,payloadString:T,generateHeaderString:(q)=>{return`t=${z},${L}=${q}`}}}return Z.signature=J,Z}V1.createWebhooks=kU});var L1=K((U1)=>{Object.defineProperty(U1,"__esModule",{value:!0});U1.ApiMajorVersion=U1.ApiVersion=void 0;U1.ApiVersion="2026-03-25.dahlia";U1.ApiMajorVersion="dahlia"});var w1=K((K1)=>{Object.defineProperty(K1,"__esModule",{value:!0});K1.resourceNamespace=void 0;function NU($,Z){for(let J in Z){if(!Object.prototype.hasOwnProperty.call(Z,J))continue;let Q=J[0].toLowerCase()+J.substring(1),X=new Z[J]($);this[Q]=X}}function xU($,Z){return function(J){return new NU(J,Z)}}K1.resourceNamespace=xU});var q1=K((D1)=>{Object.defineProperty(D1,"__esModule",{value:!0});D1.AccountLinks=void 0;var T1=w(),IU=T1.StripeResource.method;D1.AccountLinks=T1.StripeResource.extend({create:IU({method:"POST",fullPath:"/v2/core/account_links"})})});var A1=K((C1)=>{Object.defineProperty(C1,"__esModule",{value:!0});C1.AccountTokens=void 0;var F1=w(),E1=F1.StripeResource.method;C1.AccountTokens=F1.StripeResource.extend({create:E1({method:"POST",fullPath:"/v2/core/account_tokens",requestSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}}),retrieve:E1({method:"GET",fullPath:"/v2/core/account_tokens/{id}"})})});var P1=K((x1)=>{Object.defineProperty(x1,"__esModule",{value:!0});x1.Accounts=void 0;var N1=w(),Q0=N1.StripeResource.method;x1.Accounts=N1.StripeResource.extend({retrieve:Q0({method:"GET",fullPath:"/v1/financial_connections/accounts/{account}"}),list:Q0({method:"GET",fullPath:"/v1/financial_connections/accounts",methodType:"list"}),disconnect:Q0({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/disconnect"}),listOwners:Q0({method:"GET",fullPath:"/v1/financial_connections/accounts/{account}/owners",methodType:"list"}),refresh:Q0({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/refresh"}),subscribe:Q0({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/subscribe"}),unsubscribe:Q0({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/unsubscribe"})})});var y1=K((R1)=>{Object.defineProperty(R1,"__esModule",{value:!0});R1.Persons=void 0;var S1=w(),u0=S1.StripeResource.method;R1.Persons=S1.StripeResource.extend({create:u0({method:"POST",fullPath:"/v2/core/accounts/{account_id}/persons",requestSchema:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}},responseSchema:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}),retrieve:u0({method:"GET",fullPath:"/v2/core/accounts/{account_id}/persons/{id}",responseSchema:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}),update:u0({method:"POST",fullPath:"/v2/core/accounts/{account_id}/persons/{id}",requestSchema:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}},responseSchema:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}),list:u0({method:"GET",fullPath:"/v2/core/accounts/{account_id}/persons",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}),del:u0({method:"DELETE",fullPath:"/v2/core/accounts/{account_id}/persons/{id}"})})});var _1=K((f1)=>{Object.defineProperty(f1,"__esModule",{value:!0});f1.PersonTokens=void 0;var j1=w(),b1=j1.StripeResource.method;f1.PersonTokens=j1.StripeResource.extend({create:b1({method:"POST",fullPath:"/v2/core/accounts/{account_id}/person_tokens",requestSchema:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}),retrieve:b1({method:"GET",fullPath:"/v2/core/accounts/{account_id}/person_tokens/{id}"})})});var m1=K((g1)=>{Object.defineProperty(g1,"__esModule",{value:!0});g1.Accounts=void 0;var i$=w(),PU=y1(),SU=_1(),c0=i$.StripeResource.method;g1.Accounts=i$.StripeResource.extend({constructor:function(...$){i$.StripeResource.apply(this,$),this.persons=new PU.Persons(...$),this.personTokens=new SU.PersonTokens(...$)},create:c0({method:"POST",fullPath:"/v2/core/accounts",requestSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}},responseSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}}),retrieve:c0({method:"GET",fullPath:"/v2/core/accounts/{id}",responseSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}}),update:c0({method:"POST",fullPath:"/v2/core/accounts/{id}",requestSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}},responseSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}}),list:c0({method:"GET",fullPath:"/v2/core/accounts",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}}}}}),close:c0({method:"POST",fullPath:"/v2/core/accounts/{id}/close",responseSchema:{kind:"object",fields:{identity:{kind:"object",fields:{individual:{kind:"object",fields:{relationship:{kind:"object",fields:{percent_ownership:{kind:"decimal_string"}}}}}}}}}})})});var p1=K((n1)=>{Object.defineProperty(n1,"__esModule",{value:!0});n1.ActiveEntitlements=void 0;var c1=w(),u1=c1.StripeResource.method;n1.ActiveEntitlements=c1.StripeResource.extend({retrieve:u1({method:"GET",fullPath:"/v1/entitlements/active_entitlements/{id}"}),list:u1({method:"GET",fullPath:"/v1/entitlements/active_entitlements",methodType:"list"})})});var o1=K((i1)=>{Object.defineProperty(i1,"__esModule",{value:!0});i1.Alerts=void 0;var d1=w(),D0=d1.StripeResource.method;i1.Alerts=d1.StripeResource.extend({create:D0({method:"POST",fullPath:"/v1/billing/alerts"}),retrieve:D0({method:"GET",fullPath:"/v1/billing/alerts/{id}"}),list:D0({method:"GET",fullPath:"/v1/billing/alerts",methodType:"list"}),activate:D0({method:"POST",fullPath:"/v1/billing/alerts/{id}/activate"}),archive:D0({method:"POST",fullPath:"/v1/billing/alerts/{id}/archive"}),deactivate:D0({method:"POST",fullPath:"/v1/billing/alerts/{id}/deactivate"})})});var e1=K((r1)=>{Object.defineProperty(r1,"__esModule",{value:!0});r1.Associations=void 0;var s1=w(),RU=s1.StripeResource.method;r1.Associations=s1.StripeResource.extend({find:RU({method:"GET",fullPath:"/v1/tax/associations/find"})})});var Q4=K((Z4)=>{Object.defineProperty(Z4,"__esModule",{value:!0});Z4.Authorizations=void 0;var $4=w(),n0=$4.StripeResource.method;Z4.Authorizations=$4.StripeResource.extend({retrieve:n0({method:"GET",fullPath:"/v1/issuing/authorizations/{authorization}",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),update:n0({method:"POST",fullPath:"/v1/issuing/authorizations/{authorization}",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),list:n0({method:"GET",fullPath:"/v1/issuing/authorizations",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}}}}),approve:n0({method:"POST",fullPath:"/v1/issuing/authorizations/{authorization}/approve",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),decline:n0({method:"POST",fullPath:"/v1/issuing/authorizations/{authorization}/decline",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}})})});var V4=K((Y4)=>{Object.defineProperty(Y4,"__esModule",{value:!0});Y4.Authorizations=void 0;var X4=w(),X0=X4.StripeResource.method;Y4.Authorizations=X4.StripeResource.extend({create:X0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations",requestSchema:{kind:"object",fields:{fleet:{kind:"object",fields:{reported_breakdown:{kind:"object",fields:{fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},non_fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},tax:{kind:"object",fields:{local_amount_decimal:{kind:"decimal_string"},national_amount_decimal:{kind:"decimal_string"}}}}}}},fuel:{kind:"object",fields:{quantity_decimal:{kind:"decimal_string"},unit_cost_decimal:{kind:"decimal_string"}}}}},responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),capture:X0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/capture",requestSchema:{kind:"object",fields:{purchase_details:{kind:"object",fields:{fleet:{kind:"object",fields:{reported_breakdown:{kind:"object",fields:{fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},non_fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},tax:{kind:"object",fields:{local_amount_decimal:{kind:"decimal_string"},national_amount_decimal:{kind:"decimal_string"}}}}}}},fuel:{kind:"object",fields:{quantity_decimal:{kind:"decimal_string"},unit_cost_decimal:{kind:"decimal_string"}}},receipt:{kind:"array",element:{kind:"object",fields:{quantity:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),expire:X0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/expire",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),finalizeAmount:X0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/finalize_amount",requestSchema:{kind:"object",fields:{fleet:{kind:"object",fields:{reported_breakdown:{kind:"object",fields:{fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},non_fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},tax:{kind:"object",fields:{local_amount_decimal:{kind:"decimal_string"},national_amount_decimal:{kind:"decimal_string"}}}}}}},fuel:{kind:"object",fields:{quantity_decimal:{kind:"decimal_string"},unit_cost_decimal:{kind:"decimal_string"}}}}},responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),increment:X0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/increment",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),respond:X0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/fraud_challenges/respond",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}),reverse:X0({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/reverse",responseSchema:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}})})});var z4=K((W4)=>{Object.defineProperty(W4,"__esModule",{value:!0});W4.Calculations=void 0;var B4=w(),a$=B4.StripeResource.method;W4.Calculations=B4.StripeResource.extend({create:a$({method:"POST",fullPath:"/v1/tax/calculations"}),retrieve:a$({method:"GET",fullPath:"/v1/tax/calculations/{calculation}"}),listLineItems:a$({method:"GET",fullPath:"/v1/tax/calculations/{calculation}/line_items",methodType:"list"})})});var w4=K((K4)=>{Object.defineProperty(K4,"__esModule",{value:!0});K4.Cardholders=void 0;var L4=w(),S8=L4.StripeResource.method;K4.Cardholders=L4.StripeResource.extend({create:S8({method:"POST",fullPath:"/v1/issuing/cardholders"}),retrieve:S8({method:"GET",fullPath:"/v1/issuing/cardholders/{cardholder}"}),update:S8({method:"POST",fullPath:"/v1/issuing/cardholders/{cardholder}"}),list:S8({method:"GET",fullPath:"/v1/issuing/cardholders",methodType:"list"})})});var q4=K((D4)=>{Object.defineProperty(D4,"__esModule",{value:!0});D4.Cards=void 0;var T4=w(),R8=T4.StripeResource.method;D4.Cards=T4.StripeResource.extend({create:R8({method:"POST",fullPath:"/v1/issuing/cards"}),retrieve:R8({method:"GET",fullPath:"/v1/issuing/cards/{card}"}),update:R8({method:"POST",fullPath:"/v1/issuing/cards/{card}"}),list:R8({method:"GET",fullPath:"/v1/issuing/cards",methodType:"list"})})});var k4=K((F4)=>{Object.defineProperty(F4,"__esModule",{value:!0});F4.Cards=void 0;var E4=w(),l0=E4.StripeResource.method;F4.Cards=E4.StripeResource.extend({deliverCard:l0({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/deliver"}),failCard:l0({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/fail"}),returnCard:l0({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/return"}),shipCard:l0({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/ship"}),submitCard:l0({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/submit"})})});var I4=K((N4)=>{Object.defineProperty(N4,"__esModule",{value:!0});N4.Configurations=void 0;var A4=w(),v8=A4.StripeResource.method;N4.Configurations=A4.StripeResource.extend({create:v8({method:"POST",fullPath:"/v1/billing_portal/configurations"}),retrieve:v8({method:"GET",fullPath:"/v1/billing_portal/configurations/{configuration}"}),update:v8({method:"POST",fullPath:"/v1/billing_portal/configurations/{configuration}"}),list:v8({method:"GET",fullPath:"/v1/billing_portal/configurations",methodType:"list"})})});var v4=K((S4)=>{Object.defineProperty(S4,"__esModule",{value:!0});S4.Configurations=void 0;var P4=w(),p0=P4.StripeResource.method;S4.Configurations=P4.StripeResource.extend({create:p0({method:"POST",fullPath:"/v1/terminal/configurations"}),retrieve:p0({method:"GET",fullPath:"/v1/terminal/configurations/{configuration}"}),update:p0({method:"POST",fullPath:"/v1/terminal/configurations/{configuration}"}),list:p0({method:"GET",fullPath:"/v1/terminal/configurations",methodType:"list"}),del:p0({method:"DELETE",fullPath:"/v1/terminal/configurations/{configuration}"})})});var f4=K((b4)=>{Object.defineProperty(b4,"__esModule",{value:!0});b4.ConfirmationTokens=void 0;var y4=w(),vU=y4.StripeResource.method;b4.ConfirmationTokens=y4.StripeResource.extend({create:vU({method:"POST",fullPath:"/v1/test_helpers/confirmation_tokens"})})});var h4=K((_4)=>{Object.defineProperty(_4,"__esModule",{value:!0});_4.ConnectionTokens=void 0;var M4=w(),yU=M4.StripeResource.method;_4.ConnectionTokens=M4.StripeResource.extend({create:yU({method:"POST",fullPath:"/v1/terminal/connection_tokens"})})});var n4=K((u4)=>{Object.defineProperty(u4,"__esModule",{value:!0});u4.CreditBalanceSummary=void 0;var m4=w(),bU=m4.StripeResource.method;u4.CreditBalanceSummary=m4.StripeResource.extend({retrieve:bU({method:"GET",fullPath:"/v1/billing/credit_balance_summary"})})});var a4=K((d4)=>{Object.defineProperty(d4,"__esModule",{value:!0});d4.CreditBalanceTransactions=void 0;var p4=w(),l4=p4.StripeResource.method;d4.CreditBalanceTransactions=p4.StripeResource.extend({retrieve:l4({method:"GET",fullPath:"/v1/billing/credit_balance_transactions/{id}"}),list:l4({method:"GET",fullPath:"/v1/billing/credit_balance_transactions",methodType:"list"})})});var t4=K((s4)=>{Object.defineProperty(s4,"__esModule",{value:!0});s4.CreditGrants=void 0;var o4=w(),O0=o4.StripeResource.method;s4.CreditGrants=o4.StripeResource.extend({create:O0({method:"POST",fullPath:"/v1/billing/credit_grants"}),retrieve:O0({method:"GET",fullPath:"/v1/billing/credit_grants/{id}"}),update:O0({method:"POST",fullPath:"/v1/billing/credit_grants/{id}"}),list:O0({method:"GET",fullPath:"/v1/billing/credit_grants",methodType:"list"}),expire:O0({method:"POST",fullPath:"/v1/billing/credit_grants/{id}/expire"}),voidGrant:O0({method:"POST",fullPath:"/v1/billing/credit_grants/{id}/void"})})});var J6=K(($6)=>{Object.defineProperty($6,"__esModule",{value:!0});$6.CreditReversals=void 0;var e4=w(),o$=e4.StripeResource.method;$6.CreditReversals=e4.StripeResource.extend({create:o$({method:"POST",fullPath:"/v1/treasury/credit_reversals"}),retrieve:o$({method:"GET",fullPath:"/v1/treasury/credit_reversals/{credit_reversal}"}),list:o$({method:"GET",fullPath:"/v1/treasury/credit_reversals",methodType:"list"})})});var G6=K((X6)=>{Object.defineProperty(X6,"__esModule",{value:!0});X6.Customers=void 0;var Q6=w(),jU=Q6.StripeResource.method;X6.Customers=Q6.StripeResource.extend({fundCashBalance:jU({method:"POST",fullPath:"/v1/test_helpers/customers/{customer}/fund_cash_balance"})})});var U6=K((B6)=>{Object.defineProperty(B6,"__esModule",{value:!0});B6.DebitReversals=void 0;var V6=w(),s$=V6.StripeResource.method;B6.DebitReversals=V6.StripeResource.extend({create:s$({method:"POST",fullPath:"/v1/treasury/debit_reversals"}),retrieve:s$({method:"GET",fullPath:"/v1/treasury/debit_reversals/{debit_reversal}"}),list:s$({method:"GET",fullPath:"/v1/treasury/debit_reversals",methodType:"list"})})});var H6=K((L6)=>{Object.defineProperty(L6,"__esModule",{value:!0});L6.Disputes=void 0;var z6=w(),d0=z6.StripeResource.method;L6.Disputes=z6.StripeResource.extend({create:d0({method:"POST",fullPath:"/v1/issuing/disputes"}),retrieve:d0({method:"GET",fullPath:"/v1/issuing/disputes/{dispute}"}),update:d0({method:"POST",fullPath:"/v1/issuing/disputes/{dispute}"}),list:d0({method:"GET",fullPath:"/v1/issuing/disputes",methodType:"list"}),submit:d0({method:"POST",fullPath:"/v1/issuing/disputes/{dispute}/submit"})})});var q6=K((D6)=>{Object.defineProperty(D6,"__esModule",{value:!0});D6.EarlyFraudWarnings=void 0;var T6=w(),w6=T6.StripeResource.method;D6.EarlyFraudWarnings=T6.StripeResource.extend({retrieve:w6({method:"GET",fullPath:"/v1/radar/early_fraud_warnings/{early_fraud_warning}"}),list:w6({method:"GET",fullPath:"/v1/radar/early_fraud_warnings",methodType:"list"})})});var k6=K((F6)=>{Object.defineProperty(F6,"__esModule",{value:!0});F6.EventDestinations=void 0;var E6=w(),s=E6.StripeResource.method;F6.EventDestinations=E6.StripeResource.extend({create:s({method:"POST",fullPath:"/v2/core/event_destinations"}),retrieve:s({method:"GET",fullPath:"/v2/core/event_destinations/{id}"}),update:s({method:"POST",fullPath:"/v2/core/event_destinations/{id}"}),list:s({method:"GET",fullPath:"/v2/core/event_destinations",methodType:"list"}),del:s({method:"DELETE",fullPath:"/v2/core/event_destinations/{id}"}),disable:s({method:"POST",fullPath:"/v2/core/event_destinations/{id}/disable"}),enable:s({method:"POST",fullPath:"/v2/core/event_destinations/{id}/enable"}),ping:s({method:"POST",fullPath:"/v2/core/event_destinations/{id}/ping"})})});var I6=K((N6)=>{Object.defineProperty(N6,"__esModule",{value:!0});N6.Events=void 0;var A6=w(),r$=A6.StripeResource.method;N6.Events=A6.StripeResource.extend({retrieve(...$){return r$({method:"GET",fullPath:"/v2/core/events/{id}",transformResponseData:(J)=>{return this.addFetchRelatedObjectIfNeeded(J)}}).apply(this,$)},list(...$){return r$({method:"GET",fullPath:"/v2/core/events",methodType:"list",transformResponseData:(J)=>{return{...J,data:J.data.map(this.addFetchRelatedObjectIfNeeded.bind(this))}}}).apply(this,$)},addFetchRelatedObjectIfNeeded($){if(!$.related_object||!$.related_object.url)return $;return{...$,fetchRelatedObject:()=>r$({method:"GET",fullPath:$.related_object.url}).apply(this,[{stripeContext:$.context,headers:{"Stripe-Request-Trigger":`event=${$.id}`}}])}}})});var v6=K((S6)=>{Object.defineProperty(S6,"__esModule",{value:!0});S6.Features=void 0;var P6=w(),y8=P6.StripeResource.method;S6.Features=P6.StripeResource.extend({create:y8({method:"POST",fullPath:"/v1/entitlements/features"}),retrieve:y8({method:"GET",fullPath:"/v1/entitlements/features/{id}"}),update:y8({method:"POST",fullPath:"/v1/entitlements/features/{id}"}),list:y8({method:"GET",fullPath:"/v1/entitlements/features",methodType:"list"})})});var f6=K((b6)=>{Object.defineProperty(b6,"__esModule",{value:!0});b6.FinancialAccounts=void 0;var y6=w(),Y0=y6.StripeResource.method;b6.FinancialAccounts=y6.StripeResource.extend({create:Y0({method:"POST",fullPath:"/v1/treasury/financial_accounts"}),retrieve:Y0({method:"GET",fullPath:"/v1/treasury/financial_accounts/{financial_account}"}),update:Y0({method:"POST",fullPath:"/v1/treasury/financial_accounts/{financial_account}"}),list:Y0({method:"GET",fullPath:"/v1/treasury/financial_accounts",methodType:"list"}),close:Y0({method:"POST",fullPath:"/v1/treasury/financial_accounts/{financial_account}/close"}),retrieveFeatures:Y0({method:"GET",fullPath:"/v1/treasury/financial_accounts/{financial_account}/features"}),updateFeatures:Y0({method:"POST",fullPath:"/v1/treasury/financial_accounts/{financial_account}/features"})})});var h6=K((_6)=>{Object.defineProperty(_6,"__esModule",{value:!0});_6.InboundTransfers=void 0;var M6=w(),t$=M6.StripeResource.method;_6.InboundTransfers=M6.StripeResource.extend({fail:t$({method:"POST",fullPath:"/v1/test_helpers/treasury/inbound_transfers/{id}/fail"}),returnInboundTransfer:t$({method:"POST",fullPath:"/v1/test_helpers/treasury/inbound_transfers/{id}/return"}),succeed:t$({method:"POST",fullPath:"/v1/test_helpers/treasury/inbound_transfers/{id}/succeed"})})});var n6=K((u6)=>{Object.defineProperty(u6,"__esModule",{value:!0});u6.InboundTransfers=void 0;var m6=w(),b8=m6.StripeResource.method;u6.InboundTransfers=m6.StripeResource.extend({create:b8({method:"POST",fullPath:"/v1/treasury/inbound_transfers"}),retrieve:b8({method:"GET",fullPath:"/v1/treasury/inbound_transfers/{id}"}),list:b8({method:"GET",fullPath:"/v1/treasury/inbound_transfers",methodType:"list"}),cancel:b8({method:"POST",fullPath:"/v1/treasury/inbound_transfers/{inbound_transfer}/cancel"})})});var i6=K((p6)=>{Object.defineProperty(p6,"__esModule",{value:!0});p6.Locations=void 0;var l6=w(),i0=l6.StripeResource.method;p6.Locations=l6.StripeResource.extend({create:i0({method:"POST",fullPath:"/v1/terminal/locations"}),retrieve:i0({method:"GET",fullPath:"/v1/terminal/locations/{location}"}),update:i0({method:"POST",fullPath:"/v1/terminal/locations/{location}"}),list:i0({method:"GET",fullPath:"/v1/terminal/locations",methodType:"list"}),del:i0({method:"DELETE",fullPath:"/v1/terminal/locations/{location}"})})});var r6=K((o6)=>{Object.defineProperty(o6,"__esModule",{value:!0});o6.MeterEventAdjustments=void 0;var a6=w(),fU=a6.StripeResource.method;o6.MeterEventAdjustments=a6.StripeResource.extend({create:fU({method:"POST",fullPath:"/v1/billing/meter_event_adjustments"})})});var Z7=K((e6)=>{Object.defineProperty(e6,"__esModule",{value:!0});e6.MeterEventAdjustments=void 0;var t6=w(),MU=t6.StripeResource.method;e6.MeterEventAdjustments=t6.StripeResource.extend({create:MU({method:"POST",fullPath:"/v2/billing/meter_event_adjustments"})})});var Y7=K((Q7)=>{Object.defineProperty(Q7,"__esModule",{value:!0});Q7.MeterEventSession=void 0;var J7=w(),_U=J7.StripeResource.method;Q7.MeterEventSession=J7.StripeResource.extend({create:_U({method:"POST",fullPath:"/v2/billing/meter_event_session"})})});var W7=K((V7)=>{Object.defineProperty(V7,"__esModule",{value:!0});V7.MeterEventStream=void 0;var G7=w(),gU=G7.StripeResource.method;V7.MeterEventStream=G7.StripeResource.extend({create:gU({method:"POST",fullPath:"/v2/billing/meter_event_stream",host:"meter-events.stripe.com"})})});var K7=K((z7)=>{Object.defineProperty(z7,"__esModule",{value:!0});z7.MeterEvents=void 0;var U7=w(),hU=U7.StripeResource.method;z7.MeterEvents=U7.StripeResource.extend({create:hU({method:"POST",fullPath:"/v1/billing/meter_events"})})});var D7=K((w7)=>{Object.defineProperty(w7,"__esModule",{value:!0});w7.MeterEvents=void 0;var H7=w(),mU=H7.StripeResource.method;w7.MeterEvents=H7.StripeResource.extend({create:mU({method:"POST",fullPath:"/v2/billing/meter_events"})})});var F7=K((q7)=>{Object.defineProperty(q7,"__esModule",{value:!0});q7.Meters=void 0;var O7=w(),G0=O7.StripeResource.method;q7.Meters=O7.StripeResource.extend({create:G0({method:"POST",fullPath:"/v1/billing/meters"}),retrieve:G0({method:"GET",fullPath:"/v1/billing/meters/{id}"}),update:G0({method:"POST",fullPath:"/v1/billing/meters/{id}"}),list:G0({method:"GET",fullPath:"/v1/billing/meters",methodType:"list"}),deactivate:G0({method:"POST",fullPath:"/v1/billing/meters/{id}/deactivate"}),listEventSummaries:G0({method:"GET",fullPath:"/v1/billing/meters/{id}/event_summaries",methodType:"list"}),reactivate:G0({method:"POST",fullPath:"/v1/billing/meters/{id}/reactivate"})})});var N7=K((k7)=>{Object.defineProperty(k7,"__esModule",{value:!0});k7.OnboardingLinks=void 0;var C7=w(),uU=C7.StripeResource.method;k7.OnboardingLinks=C7.StripeResource.extend({create:uU({method:"POST",fullPath:"/v1/terminal/onboarding_links"})})});var S7=K((I7)=>{Object.defineProperty(I7,"__esModule",{value:!0});I7.Orders=void 0;var x7=w(),a0=x7.StripeResource.method;I7.Orders=x7.StripeResource.extend({create:a0({method:"POST",fullPath:"/v1/climate/orders",requestSchema:{kind:"object",fields:{metric_tons:{kind:"decimal_string"}}},responseSchema:{kind:"object",fields:{metric_tons:{kind:"decimal_string"}}}}),retrieve:a0({method:"GET",fullPath:"/v1/climate/orders/{order}",responseSchema:{kind:"object",fields:{metric_tons:{kind:"decimal_string"}}}}),update:a0({method:"POST",fullPath:"/v1/climate/orders/{order}",responseSchema:{kind:"object",fields:{metric_tons:{kind:"decimal_string"}}}}),list:a0({method:"GET",fullPath:"/v1/climate/orders",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{metric_tons:{kind:"decimal_string"}}}}}}}),cancel:a0({method:"POST",fullPath:"/v1/climate/orders/{order}/cancel",responseSchema:{kind:"object",fields:{metric_tons:{kind:"decimal_string"}}}})})});var b7=K((v7)=>{Object.defineProperty(v7,"__esModule",{value:!0});v7.OutboundPayments=void 0;var R7=w(),j8=R7.StripeResource.method;v7.OutboundPayments=R7.StripeResource.extend({update:j8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}"}),fail:j8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}/fail"}),post:j8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}/post"}),returnOutboundPayment:j8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}/return"})})});var _7=K((f7)=>{Object.defineProperty(f7,"__esModule",{value:!0});f7.OutboundPayments=void 0;var j7=w(),f8=j7.StripeResource.method;f7.OutboundPayments=j7.StripeResource.extend({create:f8({method:"POST",fullPath:"/v1/treasury/outbound_payments"}),retrieve:f8({method:"GET",fullPath:"/v1/treasury/outbound_payments/{id}"}),list:f8({method:"GET",fullPath:"/v1/treasury/outbound_payments",methodType:"list"}),cancel:f8({method:"POST",fullPath:"/v1/treasury/outbound_payments/{id}/cancel"})})});var u7=K((h7)=>{Object.defineProperty(h7,"__esModule",{value:!0});h7.OutboundTransfers=void 0;var g7=w(),M8=g7.StripeResource.method;h7.OutboundTransfers=g7.StripeResource.extend({update:M8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}"}),fail:M8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/fail"}),post:M8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/post"}),returnOutboundTransfer:M8({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/return"})})});var p7=K((n7)=>{Object.defineProperty(n7,"__esModule",{value:!0});n7.OutboundTransfers=void 0;var c7=w(),_8=c7.StripeResource.method;n7.OutboundTransfers=c7.StripeResource.extend({create:_8({method:"POST",fullPath:"/v1/treasury/outbound_transfers"}),retrieve:_8({method:"GET",fullPath:"/v1/treasury/outbound_transfers/{outbound_transfer}"}),list:_8({method:"GET",fullPath:"/v1/treasury/outbound_transfers",methodType:"list"}),cancel:_8({method:"POST",fullPath:"/v1/treasury/outbound_transfers/{outbound_transfer}/cancel"})})});var o7=K((i7)=>{Object.defineProperty(i7,"__esModule",{value:!0});i7.PaymentEvaluations=void 0;var d7=w(),cU=d7.StripeResource.method;i7.PaymentEvaluations=d7.StripeResource.extend({create:cU({method:"POST",fullPath:"/v1/radar/payment_evaluations"})})});var e7=K((r7)=>{Object.defineProperty(r7,"__esModule",{value:!0});r7.PersonalizationDesigns=void 0;var s7=w(),g8=s7.StripeResource.method;r7.PersonalizationDesigns=s7.StripeResource.extend({create:g8({method:"POST",fullPath:"/v1/issuing/personalization_designs"}),retrieve:g8({method:"GET",fullPath:"/v1/issuing/personalization_designs/{personalization_design}"}),update:g8({method:"POST",fullPath:"/v1/issuing/personalization_designs/{personalization_design}"}),list:g8({method:"GET",fullPath:"/v1/issuing/personalization_designs",methodType:"list"})})});var QJ=K((ZJ)=>{Object.defineProperty(ZJ,"__esModule",{value:!0});ZJ.PersonalizationDesigns=void 0;var $J=w(),e$=$J.StripeResource.method;ZJ.PersonalizationDesigns=$J.StripeResource.extend({activate:e$({method:"POST",fullPath:"/v1/test_helpers/issuing/personalization_designs/{personalization_design}/activate"}),deactivate:e$({method:"POST",fullPath:"/v1/test_helpers/issuing/personalization_designs/{personalization_design}/deactivate"}),reject:e$({method:"POST",fullPath:"/v1/test_helpers/issuing/personalization_designs/{personalization_design}/reject"})})});var BJ=K((GJ)=>{Object.defineProperty(GJ,"__esModule",{value:!0});GJ.PhysicalBundles=void 0;var YJ=w(),XJ=YJ.StripeResource.method;GJ.PhysicalBundles=YJ.StripeResource.extend({retrieve:XJ({method:"GET",fullPath:"/v1/issuing/physical_bundles/{physical_bundle}"}),list:XJ({method:"GET",fullPath:"/v1/issuing/physical_bundles",methodType:"list"})})});var KJ=K((zJ)=>{Object.defineProperty(zJ,"__esModule",{value:!0});zJ.Products=void 0;var UJ=w(),WJ=UJ.StripeResource.method;zJ.Products=UJ.StripeResource.extend({retrieve:WJ({method:"GET",fullPath:"/v1/climate/products/{product}",responseSchema:{kind:"object",fields:{metric_tons_available:{kind:"decimal_string"}}}}),list:WJ({method:"GET",fullPath:"/v1/climate/products",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{metric_tons_available:{kind:"decimal_string"}}}}}}})})});var DJ=K((wJ)=>{Object.defineProperty(wJ,"__esModule",{value:!0});wJ.Readers=void 0;var HJ=w(),f=HJ.StripeResource.method;wJ.Readers=HJ.StripeResource.extend({create:f({method:"POST",fullPath:"/v1/terminal/readers"}),retrieve:f({method:"GET",fullPath:"/v1/terminal/readers/{reader}"}),update:f({method:"POST",fullPath:"/v1/terminal/readers/{reader}"}),list:f({method:"GET",fullPath:"/v1/terminal/readers",methodType:"list"}),del:f({method:"DELETE",fullPath:"/v1/terminal/readers/{reader}"}),cancelAction:f({method:"POST",fullPath:"/v1/terminal/readers/{reader}/cancel_action"}),collectInputs:f({method:"POST",fullPath:"/v1/terminal/readers/{reader}/collect_inputs"}),collectPaymentMethod:f({method:"POST",fullPath:"/v1/terminal/readers/{reader}/collect_payment_method"}),confirmPaymentIntent:f({method:"POST",fullPath:"/v1/terminal/readers/{reader}/confirm_payment_intent"}),processPaymentIntent:f({method:"POST",fullPath:"/v1/terminal/readers/{reader}/process_payment_intent"}),processSetupIntent:f({method:"POST",fullPath:"/v1/terminal/readers/{reader}/process_setup_intent"}),refundPayment:f({method:"POST",fullPath:"/v1/terminal/readers/{reader}/refund_payment"}),setReaderDisplay:f({method:"POST",fullPath:"/v1/terminal/readers/{reader}/set_reader_display"})})});var FJ=K((qJ)=>{Object.defineProperty(qJ,"__esModule",{value:!0});qJ.Readers=void 0;var OJ=w(),$9=OJ.StripeResource.method;qJ.Readers=OJ.StripeResource.extend({presentPaymentMethod:$9({method:"POST",fullPath:"/v1/test_helpers/terminal/readers/{reader}/present_payment_method"}),succeedInputCollection:$9({method:"POST",fullPath:"/v1/test_helpers/terminal/readers/{reader}/succeed_input_collection"}),timeoutInputCollection:$9({method:"POST",fullPath:"/v1/test_helpers/terminal/readers/{reader}/timeout_input_collection"})})});var NJ=K((kJ)=>{Object.defineProperty(kJ,"__esModule",{value:!0});kJ.ReceivedCredits=void 0;var CJ=w(),nU=CJ.StripeResource.method;kJ.ReceivedCredits=CJ.StripeResource.extend({create:nU({method:"POST",fullPath:"/v1/test_helpers/treasury/received_credits"})})});var RJ=K((PJ)=>{Object.defineProperty(PJ,"__esModule",{value:!0});PJ.ReceivedCredits=void 0;var IJ=w(),xJ=IJ.StripeResource.method;PJ.ReceivedCredits=IJ.StripeResource.extend({retrieve:xJ({method:"GET",fullPath:"/v1/treasury/received_credits/{id}"}),list:xJ({method:"GET",fullPath:"/v1/treasury/received_credits",methodType:"list"})})});var jJ=K((yJ)=>{Object.defineProperty(yJ,"__esModule",{value:!0});yJ.ReceivedDebits=void 0;var vJ=w(),lU=vJ.StripeResource.method;yJ.ReceivedDebits=vJ.StripeResource.extend({create:lU({method:"POST",fullPath:"/v1/test_helpers/treasury/received_debits"})})});var hJ=K((_J)=>{Object.defineProperty(_J,"__esModule",{value:!0});_J.ReceivedDebits=void 0;var MJ=w(),fJ=MJ.StripeResource.method;_J.ReceivedDebits=MJ.StripeResource.extend({retrieve:fJ({method:"GET",fullPath:"/v1/treasury/received_debits/{id}"}),list:fJ({method:"GET",fullPath:"/v1/treasury/received_debits",methodType:"list"})})});var nJ=K((uJ)=>{Object.defineProperty(uJ,"__esModule",{value:!0});uJ.Refunds=void 0;var mJ=w(),pU=mJ.StripeResource.method;uJ.Refunds=mJ.StripeResource.extend({expire:pU({method:"POST",fullPath:"/v1/test_helpers/refunds/{refund}/expire"})})});var iJ=K((pJ)=>{Object.defineProperty(pJ,"__esModule",{value:!0});pJ.Registrations=void 0;var lJ=w(),h8=lJ.StripeResource.method;pJ.Registrations=lJ.StripeResource.extend({create:h8({method:"POST",fullPath:"/v1/tax/registrations"}),retrieve:h8({method:"GET",fullPath:"/v1/tax/registrations/{id}"}),update:h8({method:"POST",fullPath:"/v1/tax/registrations/{id}"}),list:h8({method:"GET",fullPath:"/v1/tax/registrations",methodType:"list"})})});var rJ=K((oJ)=>{Object.defineProperty(oJ,"__esModule",{value:!0});oJ.ReportRuns=void 0;var aJ=w(),Z9=aJ.StripeResource.method;oJ.ReportRuns=aJ.StripeResource.extend({create:Z9({method:"POST",fullPath:"/v1/reporting/report_runs"}),retrieve:Z9({method:"GET",fullPath:"/v1/reporting/report_runs/{report_run}"}),list:Z9({method:"GET",fullPath:"/v1/reporting/report_runs",methodType:"list"})})});var J5=K(($5)=>{Object.defineProperty($5,"__esModule",{value:!0});$5.ReportTypes=void 0;var eJ=w(),tJ=eJ.StripeResource.method;$5.ReportTypes=eJ.StripeResource.extend({retrieve:tJ({method:"GET",fullPath:"/v1/reporting/report_types/{report_type}"}),list:tJ({method:"GET",fullPath:"/v1/reporting/report_types",methodType:"list"})})});var G5=K((X5)=>{Object.defineProperty(X5,"__esModule",{value:!0});X5.Requests=void 0;var Q5=w(),J9=Q5.StripeResource.method;X5.Requests=Q5.StripeResource.extend({create:J9({method:"POST",fullPath:"/v1/forwarding/requests"}),retrieve:J9({method:"GET",fullPath:"/v1/forwarding/requests/{id}"}),list:J9({method:"GET",fullPath:"/v1/forwarding/requests",methodType:"list"})})});var z5=K((W5)=>{Object.defineProperty(W5,"__esModule",{value:!0});W5.ScheduledQueryRuns=void 0;var B5=w(),V5=B5.StripeResource.method;W5.ScheduledQueryRuns=B5.StripeResource.extend({retrieve:V5({method:"GET",fullPath:"/v1/sigma/scheduled_query_runs/{scheduled_query_run}"}),list:V5({method:"GET",fullPath:"/v1/sigma/scheduled_query_runs",methodType:"list"})})});var w5=K((K5)=>{Object.defineProperty(K5,"__esModule",{value:!0});K5.Secrets=void 0;var L5=w(),m8=L5.StripeResource.method;K5.Secrets=L5.StripeResource.extend({create:m8({method:"POST",fullPath:"/v1/apps/secrets"}),list:m8({method:"GET",fullPath:"/v1/apps/secrets",methodType:"list"}),deleteWhere:m8({method:"POST",fullPath:"/v1/apps/secrets/delete"}),find:m8({method:"GET",fullPath:"/v1/apps/secrets/find"})})});var q5=K((D5)=>{Object.defineProperty(D5,"__esModule",{value:!0});D5.Sessions=void 0;var T5=w(),dU=T5.StripeResource.method;D5.Sessions=T5.StripeResource.extend({create:dU({method:"POST",fullPath:"/v1/billing_portal/sessions"})})});var k5=K((F5)=>{Object.defineProperty(F5,"__esModule",{value:!0});F5.Sessions=void 0;var E5=w(),q0=E5.StripeResource.method;F5.Sessions=E5.StripeResource.extend({create:q0({method:"POST",fullPath:"/v1/checkout/sessions",requestSchema:{kind:"object",fields:{line_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{currency_conversion:{kind:"nullable",inner:{kind:"object",fields:{fx_rate:{kind:"decimal_string"}}}},line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),retrieve:q0({method:"GET",fullPath:"/v1/checkout/sessions/{session}",responseSchema:{kind:"object",fields:{currency_conversion:{kind:"nullable",inner:{kind:"object",fields:{fx_rate:{kind:"decimal_string"}}}},line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),update:q0({method:"POST",fullPath:"/v1/checkout/sessions/{session}",requestSchema:{kind:"object",fields:{line_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{currency_conversion:{kind:"nullable",inner:{kind:"object",fields:{fx_rate:{kind:"decimal_string"}}}},line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),list:q0({method:"GET",fullPath:"/v1/checkout/sessions",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{currency_conversion:{kind:"nullable",inner:{kind:"object",fields:{fx_rate:{kind:"decimal_string"}}}},line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}),expire:q0({method:"POST",fullPath:"/v1/checkout/sessions/{session}/expire",responseSchema:{kind:"object",fields:{currency_conversion:{kind:"nullable",inner:{kind:"object",fields:{fx_rate:{kind:"decimal_string"}}}},line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),listLineItems:q0({method:"GET",fullPath:"/v1/checkout/sessions/{session}/line_items",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}})})});var P5=K((x5)=>{Object.defineProperty(x5,"__esModule",{value:!0});x5.Sessions=void 0;var N5=w(),A5=N5.StripeResource.method;x5.Sessions=N5.StripeResource.extend({create:A5({method:"POST",fullPath:"/v1/financial_connections/sessions"}),retrieve:A5({method:"GET",fullPath:"/v1/financial_connections/sessions/{session}"})})});var b5=K((v5)=>{Object.defineProperty(v5,"__esModule",{value:!0});v5.Settings=void 0;var R5=w(),S5=R5.StripeResource.method;v5.Settings=R5.StripeResource.extend({retrieve:S5({method:"GET",fullPath:"/v1/tax/settings"}),update:S5({method:"POST",fullPath:"/v1/tax/settings"})})});var g5=K((M5)=>{Object.defineProperty(M5,"__esModule",{value:!0});M5.Suppliers=void 0;var f5=w(),j5=f5.StripeResource.method;M5.Suppliers=f5.StripeResource.extend({retrieve:j5({method:"GET",fullPath:"/v1/climate/suppliers/{supplier}"}),list:j5({method:"GET",fullPath:"/v1/climate/suppliers",methodType:"list"})})});var c5=K((m5)=>{Object.defineProperty(m5,"__esModule",{value:!0});m5.TestClocks=void 0;var h5=w(),o0=h5.StripeResource.method;m5.TestClocks=h5.StripeResource.extend({create:o0({method:"POST",fullPath:"/v1/test_helpers/test_clocks"}),retrieve:o0({method:"GET",fullPath:"/v1/test_helpers/test_clocks/{test_clock}"}),list:o0({method:"GET",fullPath:"/v1/test_helpers/test_clocks",methodType:"list"}),del:o0({method:"DELETE",fullPath:"/v1/test_helpers/test_clocks/{test_clock}"}),advance:o0({method:"POST",fullPath:"/v1/test_helpers/test_clocks/{test_clock}/advance"})})});var d5=K((l5)=>{Object.defineProperty(l5,"__esModule",{value:!0});l5.Tokens=void 0;var n5=w(),Q9=n5.StripeResource.method;l5.Tokens=n5.StripeResource.extend({retrieve:Q9({method:"GET",fullPath:"/v1/issuing/tokens/{token}"}),update:Q9({method:"POST",fullPath:"/v1/issuing/tokens/{token}"}),list:Q9({method:"GET",fullPath:"/v1/issuing/tokens",methodType:"list"})})});var r5=K((o5)=>{Object.defineProperty(o5,"__esModule",{value:!0});o5.TransactionEntries=void 0;var a5=w(),i5=a5.StripeResource.method;o5.TransactionEntries=a5.StripeResource.extend({retrieve:i5({method:"GET",fullPath:"/v1/treasury/transaction_entries/{id}",responseSchema:{kind:"object",fields:{flow_details:{kind:"nullable",inner:{kind:"object",fields:{issuing_authorization:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}),list:i5({method:"GET",fullPath:"/v1/treasury/transaction_entries",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{flow_details:{kind:"nullable",inner:{kind:"object",fields:{issuing_authorization:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}})})});var JQ=K(($Q)=>{Object.defineProperty($Q,"__esModule",{value:!0});$Q.Transactions=void 0;var e5=w(),t5=e5.StripeResource.method;$Q.Transactions=e5.StripeResource.extend({retrieve:t5({method:"GET",fullPath:"/v1/financial_connections/transactions/{transaction}"}),list:t5({method:"GET",fullPath:"/v1/financial_connections/transactions",methodType:"list"})})});var GQ=K((XQ)=>{Object.defineProperty(XQ,"__esModule",{value:!0});XQ.Transactions=void 0;var QQ=w(),X9=QQ.StripeResource.method;XQ.Transactions=QQ.StripeResource.extend({retrieve:X9({method:"GET",fullPath:"/v1/issuing/transactions/{transaction}",responseSchema:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}),update:X9({method:"POST",fullPath:"/v1/issuing/transactions/{transaction}",responseSchema:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}),list:X9({method:"GET",fullPath:"/v1/issuing/transactions",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}})})});var UQ=K((BQ)=>{Object.defineProperty(BQ,"__esModule",{value:!0});BQ.Transactions=void 0;var VQ=w(),u8=VQ.StripeResource.method;BQ.Transactions=VQ.StripeResource.extend({retrieve:u8({method:"GET",fullPath:"/v1/tax/transactions/{transaction}"}),createFromCalculation:u8({method:"POST",fullPath:"/v1/tax/transactions/create_from_calculation"}),createReversal:u8({method:"POST",fullPath:"/v1/tax/transactions/create_reversal"}),listLineItems:u8({method:"GET",fullPath:"/v1/tax/transactions/{transaction}/line_items",methodType:"list"})})});var HQ=K((LQ)=>{Object.defineProperty(LQ,"__esModule",{value:!0});LQ.Transactions=void 0;var zQ=w(),Y9=zQ.StripeResource.method;LQ.Transactions=zQ.StripeResource.extend({createForceCapture:Y9({method:"POST",fullPath:"/v1/test_helpers/issuing/transactions/create_force_capture",requestSchema:{kind:"object",fields:{purchase_details:{kind:"object",fields:{fleet:{kind:"object",fields:{reported_breakdown:{kind:"object",fields:{fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},non_fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},tax:{kind:"object",fields:{local_amount_decimal:{kind:"decimal_string"},national_amount_decimal:{kind:"decimal_string"}}}}}}},fuel:{kind:"object",fields:{quantity_decimal:{kind:"decimal_string"},unit_cost_decimal:{kind:"decimal_string"}}},receipt:{kind:"array",element:{kind:"object",fields:{quantity:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}),createUnlinkedRefund:Y9({method:"POST",fullPath:"/v1/test_helpers/issuing/transactions/create_unlinked_refund",requestSchema:{kind:"object",fields:{purchase_details:{kind:"object",fields:{fleet:{kind:"object",fields:{reported_breakdown:{kind:"object",fields:{fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},non_fuel:{kind:"object",fields:{gross_amount_decimal:{kind:"decimal_string"}}},tax:{kind:"object",fields:{local_amount_decimal:{kind:"decimal_string"},national_amount_decimal:{kind:"decimal_string"}}}}}}},fuel:{kind:"object",fields:{quantity_decimal:{kind:"decimal_string"},unit_cost_decimal:{kind:"decimal_string"}}},receipt:{kind:"array",element:{kind:"object",fields:{quantity:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}),refund:Y9({method:"POST",fullPath:"/v1/test_helpers/issuing/transactions/{transaction}/refund",responseSchema:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}})})});var qQ=K((DQ)=>{Object.defineProperty(DQ,"__esModule",{value:!0});DQ.Transactions=void 0;var TQ=w(),wQ=TQ.StripeResource.method;DQ.Transactions=TQ.StripeResource.extend({retrieve:wQ({method:"GET",fullPath:"/v1/treasury/transactions/{id}",responseSchema:{kind:"object",fields:{entries:{kind:"nullable",inner:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{flow_details:{kind:"nullable",inner:{kind:"object",fields:{issuing_authorization:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}),list:wQ({method:"GET",fullPath:"/v1/treasury/transactions",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{entries:{kind:"nullable",inner:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{flow_details:{kind:"nullable",inner:{kind:"object",fields:{issuing_authorization:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},transactions:{kind:"array",element:{kind:"object",fields:{purchase_details:{kind:"nullable",inner:{kind:"object",fields:{fleet:{kind:"nullable",inner:{kind:"object",fields:{reported_breakdown:{kind:"nullable",inner:{kind:"object",fields:{fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},non_fuel:{kind:"nullable",inner:{kind:"object",fields:{gross_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tax:{kind:"nullable",inner:{kind:"object",fields:{local_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},national_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}},fuel:{kind:"nullable",inner:{kind:"object",fields:{quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_cost_decimal:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}}}}}}}})})});var kQ=K((FQ)=>{Object.defineProperty(FQ,"__esModule",{value:!0});FQ.ValueListItems=void 0;var EQ=w(),c8=EQ.StripeResource.method;FQ.ValueListItems=EQ.StripeResource.extend({create:c8({method:"POST",fullPath:"/v1/radar/value_list_items"}),retrieve:c8({method:"GET",fullPath:"/v1/radar/value_list_items/{item}"}),list:c8({method:"GET",fullPath:"/v1/radar/value_list_items",methodType:"list"}),del:c8({method:"DELETE",fullPath:"/v1/radar/value_list_items/{item}"})})});var IQ=K((NQ)=>{Object.defineProperty(NQ,"__esModule",{value:!0});NQ.ValueLists=void 0;var AQ=w(),s0=AQ.StripeResource.method;NQ.ValueLists=AQ.StripeResource.extend({create:s0({method:"POST",fullPath:"/v1/radar/value_lists"}),retrieve:s0({method:"GET",fullPath:"/v1/radar/value_lists/{value_list}"}),update:s0({method:"POST",fullPath:"/v1/radar/value_lists/{value_list}"}),list:s0({method:"GET",fullPath:"/v1/radar/value_lists",methodType:"list"}),del:s0({method:"DELETE",fullPath:"/v1/radar/value_lists/{value_list}"})})});var yQ=K((RQ)=>{Object.defineProperty(RQ,"__esModule",{value:!0});RQ.VerificationReports=void 0;var SQ=w(),PQ=SQ.StripeResource.method;RQ.VerificationReports=SQ.StripeResource.extend({retrieve:PQ({method:"GET",fullPath:"/v1/identity/verification_reports/{report}"}),list:PQ({method:"GET",fullPath:"/v1/identity/verification_reports",methodType:"list"})})});var MQ=K((jQ)=>{Object.defineProperty(jQ,"__esModule",{value:!0});jQ.VerificationSessions=void 0;var bQ=w(),E0=bQ.StripeResource.method;jQ.VerificationSessions=bQ.StripeResource.extend({create:E0({method:"POST",fullPath:"/v1/identity/verification_sessions"}),retrieve:E0({method:"GET",fullPath:"/v1/identity/verification_sessions/{session}"}),update:E0({method:"POST",fullPath:"/v1/identity/verification_sessions/{session}"}),list:E0({method:"GET",fullPath:"/v1/identity/verification_sessions",methodType:"list"}),cancel:E0({method:"POST",fullPath:"/v1/identity/verification_sessions/{session}/cancel"}),redact:E0({method:"POST",fullPath:"/v1/identity/verification_sessions/{session}/redact"})})});var G9=K((gQ)=>{Object.defineProperty(gQ,"__esModule",{value:!0});gQ.Accounts=void 0;var _Q=w(),I=_Q.StripeResource.method;gQ.Accounts=_Q.StripeResource.extend({create:I({method:"POST",fullPath:"/v1/accounts"}),retrieve($,...Z){if(typeof $==="string")return I({method:"GET",fullPath:"/v1/accounts/{id}"}).apply(this,[$,...Z]);else{if($===null||$===void 0)[].shift.apply([$,...Z]);return I({method:"GET",fullPath:"/v1/account"}).apply(this,[$,...Z])}},update:I({method:"POST",fullPath:"/v1/accounts/{account}"}),list:I({method:"GET",fullPath:"/v1/accounts",methodType:"list"}),del:I({method:"DELETE",fullPath:"/v1/accounts/{account}"}),createExternalAccount:I({method:"POST",fullPath:"/v1/accounts/{account}/external_accounts"}),createLoginLink:I({method:"POST",fullPath:"/v1/accounts/{account}/login_links"}),createPerson:I({method:"POST",fullPath:"/v1/accounts/{account}/persons"}),deleteExternalAccount:I({method:"DELETE",fullPath:"/v1/accounts/{account}/external_accounts/{id}"}),deletePerson:I({method:"DELETE",fullPath:"/v1/accounts/{account}/persons/{person}"}),listCapabilities:I({method:"GET",fullPath:"/v1/accounts/{account}/capabilities",methodType:"list"}),listExternalAccounts:I({method:"GET",fullPath:"/v1/accounts/{account}/external_accounts",methodType:"list"}),listPersons:I({method:"GET",fullPath:"/v1/accounts/{account}/persons",methodType:"list"}),reject:I({method:"POST",fullPath:"/v1/accounts/{account}/reject"}),retrieveCurrent:I({method:"GET",fullPath:"/v1/account"}),retrieveCapability:I({method:"GET",fullPath:"/v1/accounts/{account}/capabilities/{capability}"}),retrieveExternalAccount:I({method:"GET",fullPath:"/v1/accounts/{account}/external_accounts/{id}"}),retrievePerson:I({method:"GET",fullPath:"/v1/accounts/{account}/persons/{person}"}),updateCapability:I({method:"POST",fullPath:"/v1/accounts/{account}/capabilities/{capability}"}),updateExternalAccount:I({method:"POST",fullPath:"/v1/accounts/{account}/external_accounts/{id}"}),updatePerson:I({method:"POST",fullPath:"/v1/accounts/{account}/persons/{person}"})})});var nQ=K((uQ)=>{Object.defineProperty(uQ,"__esModule",{value:!0});uQ.AccountLinks=void 0;var mQ=w(),iU=mQ.StripeResource.method;uQ.AccountLinks=mQ.StripeResource.extend({create:iU({method:"POST",fullPath:"/v1/account_links"})})});var iQ=K((pQ)=>{Object.defineProperty(pQ,"__esModule",{value:!0});pQ.AccountSessions=void 0;var lQ=w(),aU=lQ.StripeResource.method;pQ.AccountSessions=lQ.StripeResource.extend({create:aU({method:"POST",fullPath:"/v1/account_sessions"})})});var rQ=K((oQ)=>{Object.defineProperty(oQ,"__esModule",{value:!0});oQ.ApplePayDomains=void 0;var aQ=w(),n8=aQ.StripeResource.method;oQ.ApplePayDomains=aQ.StripeResource.extend({create:n8({method:"POST",fullPath:"/v1/apple_pay/domains"}),retrieve:n8({method:"GET",fullPath:"/v1/apple_pay/domains/{domain}"}),list:n8({method:"GET",fullPath:"/v1/apple_pay/domains",methodType:"list"}),del:n8({method:"DELETE",fullPath:"/v1/apple_pay/domains/{domain}"})})});var ZX=K((eQ)=>{Object.defineProperty(eQ,"__esModule",{value:!0});eQ.ApplicationFees=void 0;var tQ=w(),F0=tQ.StripeResource.method;eQ.ApplicationFees=tQ.StripeResource.extend({retrieve:F0({method:"GET",fullPath:"/v1/application_fees/{id}"}),list:F0({method:"GET",fullPath:"/v1/application_fees",methodType:"list"}),createRefund:F0({method:"POST",fullPath:"/v1/application_fees/{id}/refunds"}),listRefunds:F0({method:"GET",fullPath:"/v1/application_fees/{id}/refunds",methodType:"list"}),retrieveRefund:F0({method:"GET",fullPath:"/v1/application_fees/{fee}/refunds/{id}"}),updateRefund:F0({method:"POST",fullPath:"/v1/application_fees/{fee}/refunds/{id}"})})});var YX=K((QX)=>{Object.defineProperty(QX,"__esModule",{value:!0});QX.Balance=void 0;var JX=w(),oU=JX.StripeResource.method;QX.Balance=JX.StripeResource.extend({retrieve:oU({method:"GET",fullPath:"/v1/balance"})})});var UX=K((BX)=>{Object.defineProperty(BX,"__esModule",{value:!0});BX.BalanceSettings=void 0;var VX=w(),GX=VX.StripeResource.method;BX.BalanceSettings=VX.StripeResource.extend({retrieve:GX({method:"GET",fullPath:"/v1/balance_settings"}),update:GX({method:"POST",fullPath:"/v1/balance_settings"})})});var wX=K((KX)=>{Object.defineProperty(KX,"__esModule",{value:!0});KX.BalanceTransactions=void 0;var LX=w(),zX=LX.StripeResource.method;KX.BalanceTransactions=LX.StripeResource.extend({retrieve:zX({method:"GET",fullPath:"/v1/balance_transactions/{id}"}),list:zX({method:"GET",fullPath:"/v1/balance_transactions",methodType:"list"})})});var qX=K((DX)=>{Object.defineProperty(DX,"__esModule",{value:!0});DX.Charges=void 0;var TX=w(),C0=TX.StripeResource.method;DX.Charges=TX.StripeResource.extend({create:C0({method:"POST",fullPath:"/v1/charges"}),retrieve:C0({method:"GET",fullPath:"/v1/charges/{charge}"}),update:C0({method:"POST",fullPath:"/v1/charges/{charge}"}),list:C0({method:"GET",fullPath:"/v1/charges",methodType:"list"}),capture:C0({method:"POST",fullPath:"/v1/charges/{charge}/capture"}),search:C0({method:"GET",fullPath:"/v1/charges/search",methodType:"search"})})});var kX=K((FX)=>{Object.defineProperty(FX,"__esModule",{value:!0});FX.ConfirmationTokens=void 0;var EX=w(),sU=EX.StripeResource.method;FX.ConfirmationTokens=EX.StripeResource.extend({retrieve:sU({method:"GET",fullPath:"/v1/confirmation_tokens/{confirmation_token}"})})});var PX=K((xX)=>{Object.defineProperty(xX,"__esModule",{value:!0});xX.CountrySpecs=void 0;var NX=w(),AX=NX.StripeResource.method;xX.CountrySpecs=NX.StripeResource.extend({retrieve:AX({method:"GET",fullPath:"/v1/country_specs/{country}"}),list:AX({method:"GET",fullPath:"/v1/country_specs",methodType:"list"})})});var yX=K((RX)=>{Object.defineProperty(RX,"__esModule",{value:!0});RX.Coupons=void 0;var SX=w(),r0=SX.StripeResource.method;RX.Coupons=SX.StripeResource.extend({create:r0({method:"POST",fullPath:"/v1/coupons"}),retrieve:r0({method:"GET",fullPath:"/v1/coupons/{coupon}"}),update:r0({method:"POST",fullPath:"/v1/coupons/{coupon}"}),list:r0({method:"GET",fullPath:"/v1/coupons",methodType:"list"}),del:r0({method:"DELETE",fullPath:"/v1/coupons/{coupon}"})})});var MX=K((jX)=>{Object.defineProperty(jX,"__esModule",{value:!0});jX.CreditNotes=void 0;var bX=w(),r=bX.StripeResource.method;jX.CreditNotes=bX.StripeResource.extend({create:r({method:"POST",fullPath:"/v1/credit_notes",requestSchema:{kind:"object",fields:{lines:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),retrieve:r({method:"GET",fullPath:"/v1/credit_notes/{id}",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),update:r({method:"POST",fullPath:"/v1/credit_notes/{id}",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),list:r({method:"GET",fullPath:"/v1/credit_notes",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),listLineItems:r({method:"GET",fullPath:"/v1/credit_notes/{credit_note}/lines",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),listPreviewLineItems:r({method:"GET",fullPath:"/v1/credit_notes/preview/lines",methodType:"list",requestSchema:{kind:"object",fields:{lines:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),preview:r({method:"GET",fullPath:"/v1/credit_notes/preview",requestSchema:{kind:"object",fields:{lines:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),voidCreditNote:r({method:"POST",fullPath:"/v1/credit_notes/{id}/void",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}})})});var mX=K((gX)=>{Object.defineProperty(gX,"__esModule",{value:!0});gX.CustomerSessions=void 0;var _X=w(),rU=_X.StripeResource.method;gX.CustomerSessions=_X.StripeResource.extend({create:rU({method:"POST",fullPath:"/v1/customer_sessions"})})});var lX=K((cX)=>{Object.defineProperty(cX,"__esModule",{value:!0});cX.Customers=void 0;var uX=w(),A=uX.StripeResource.method;cX.Customers=uX.StripeResource.extend({create:A({method:"POST",fullPath:"/v1/customers",responseSchema:{kind:"object",fields:{subscriptions:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}),retrieve:A({method:"GET",fullPath:"/v1/customers/{customer}"}),update:A({method:"POST",fullPath:"/v1/customers/{customer}",responseSchema:{kind:"object",fields:{subscriptions:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}),list:A({method:"GET",fullPath:"/v1/customers",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{subscriptions:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}),del:A({method:"DELETE",fullPath:"/v1/customers/{customer}"}),createBalanceTransaction:A({method:"POST",fullPath:"/v1/customers/{customer}/balance_transactions"}),createFundingInstructions:A({method:"POST",fullPath:"/v1/customers/{customer}/funding_instructions"}),createSource:A({method:"POST",fullPath:"/v1/customers/{customer}/sources"}),createTaxId:A({method:"POST",fullPath:"/v1/customers/{customer}/tax_ids"}),deleteDiscount:A({method:"DELETE",fullPath:"/v1/customers/{customer}/discount"}),deleteSource:A({method:"DELETE",fullPath:"/v1/customers/{customer}/sources/{id}"}),deleteTaxId:A({method:"DELETE",fullPath:"/v1/customers/{customer}/tax_ids/{id}"}),listBalanceTransactions:A({method:"GET",fullPath:"/v1/customers/{customer}/balance_transactions",methodType:"list"}),listCashBalanceTransactions:A({method:"GET",fullPath:"/v1/customers/{customer}/cash_balance_transactions",methodType:"list"}),listPaymentMethods:A({method:"GET",fullPath:"/v1/customers/{customer}/payment_methods",methodType:"list"}),listSources:A({method:"GET",fullPath:"/v1/customers/{customer}/sources",methodType:"list"}),listTaxIds:A({method:"GET",fullPath:"/v1/customers/{customer}/tax_ids",methodType:"list"}),retrieveBalanceTransaction:A({method:"GET",fullPath:"/v1/customers/{customer}/balance_transactions/{transaction}"}),retrieveCashBalance:A({method:"GET",fullPath:"/v1/customers/{customer}/cash_balance"}),retrieveCashBalanceTransaction:A({method:"GET",fullPath:"/v1/customers/{customer}/cash_balance_transactions/{transaction}"}),retrievePaymentMethod:A({method:"GET",fullPath:"/v1/customers/{customer}/payment_methods/{payment_method}"}),retrieveSource:A({method:"GET",fullPath:"/v1/customers/{customer}/sources/{id}"}),retrieveTaxId:A({method:"GET",fullPath:"/v1/customers/{customer}/tax_ids/{id}"}),search:A({method:"GET",fullPath:"/v1/customers/search",methodType:"search",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{subscriptions:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}),updateBalanceTransaction:A({method:"POST",fullPath:"/v1/customers/{customer}/balance_transactions/{transaction}"}),updateCashBalance:A({method:"POST",fullPath:"/v1/customers/{customer}/cash_balance"}),updateSource:A({method:"POST",fullPath:"/v1/customers/{customer}/sources/{id}"}),verifySource:A({method:"POST",fullPath:"/v1/customers/{customer}/sources/{id}/verify"})})});var aX=K((dX)=>{Object.defineProperty(dX,"__esModule",{value:!0});dX.Disputes=void 0;var pX=w(),l8=pX.StripeResource.method;dX.Disputes=pX.StripeResource.extend({retrieve:l8({method:"GET",fullPath:"/v1/disputes/{dispute}"}),update:l8({method:"POST",fullPath:"/v1/disputes/{dispute}"}),list:l8({method:"GET",fullPath:"/v1/disputes",methodType:"list"}),close:l8({method:"POST",fullPath:"/v1/disputes/{dispute}/close"})})});var eX=K((rX)=>{Object.defineProperty(rX,"__esModule",{value:!0});rX.EphemeralKeys=void 0;var sX=w(),oX=sX.StripeResource.method;rX.EphemeralKeys=sX.StripeResource.extend({create:oX({method:"POST",fullPath:"/v1/ephemeral_keys",validator:($,Z)=>{if(!Z.headers||!Z.headers["Stripe-Version"])throw Error("Passing apiVersion in a separate options hash is required to create an ephemeral key. See https://stripe.com/docs/api/versioning?lang=node")}}),del:oX({method:"DELETE",fullPath:"/v1/ephemeral_keys/{key}"})})});var XY=K((JY)=>{Object.defineProperty(JY,"__esModule",{value:!0});JY.Events=void 0;var ZY=w(),$Y=ZY.StripeResource.method;JY.Events=ZY.StripeResource.extend({retrieve:$Y({method:"GET",fullPath:"/v1/events/{id}"}),list:$Y({method:"GET",fullPath:"/v1/events",methodType:"list"})})});var WY=K((VY)=>{Object.defineProperty(VY,"__esModule",{value:!0});VY.ExchangeRates=void 0;var GY=w(),YY=GY.StripeResource.method;VY.ExchangeRates=GY.StripeResource.extend({retrieve:YY({method:"GET",fullPath:"/v1/exchange_rates/{rate_id}"}),list:YY({method:"GET",fullPath:"/v1/exchange_rates",methodType:"list"})})});var KY=K((zY)=>{Object.defineProperty(zY,"__esModule",{value:!0});zY.FileLinks=void 0;var UY=w(),p8=UY.StripeResource.method;zY.FileLinks=UY.StripeResource.extend({create:p8({method:"POST",fullPath:"/v1/file_links"}),retrieve:p8({method:"GET",fullPath:"/v1/file_links/{link}"}),update:p8({method:"POST",fullPath:"/v1/file_links/{link}"}),list:p8({method:"GET",fullPath:"/v1/file_links",methodType:"list"})})});var DY=K((wY)=>{Object.defineProperty(wY,"__esModule",{value:!0});wY.multipartRequestDataProcessor=void 0;var HY=c(),tU=($,Z,J)=>{let Q=(Math.round(Math.random()*10000000000000000)+Math.round(Math.random()*10000000000000000)).toString();J["Content-Type"]=`multipart/form-data; boundary=${Q}`;let X=new TextEncoder,Y=new Uint8Array(0),G=X.encode(`\r
12
+ `);function V(B){let z=Y,L=B instanceof Uint8Array?B:new Uint8Array(X.encode(B));Y=new Uint8Array(z.length+L.length+2),Y.set(z),Y.set(L,z.length),Y.set(G,Y.length-2)}function U(B){return`"${B.replace(/"|"/g,"%22").replace(/\r\n|\r|\n/g," ")}"`}let W=(0,HY.flattenAndStringify)(Z);for(let B in W){if(!Object.prototype.hasOwnProperty.call(W,B))continue;let z=W[B];if(V(`--${Q}`),Object.prototype.hasOwnProperty.call(z,"data")){let L=z;V(`Content-Disposition: form-data; name=${U(B)}; filename=${U(L.name||"blob")}`),V(`Content-Type: ${L.type||"application/octet-stream"}`),V(""),V(L.data)}else V(`Content-Disposition: form-data; name=${U(B)}`),V(""),V(z)}return V(`--${Q}--`),Y};function eU($,Z,J,Q){if(Z=Z||{},$!=="POST")return Q(null,(0,HY.queryStringifyRequestData)(Z));this._stripe._platformFunctions.tryBufferData(Z).then((X)=>{let Y=tU($,X,J);return Q(null,Y)}).catch((X)=>Q(X,null))}wY.multipartRequestDataProcessor=eU});var FY=K((qY)=>{Object.defineProperty(qY,"__esModule",{value:!0});qY.Files=void 0;var $z=DY(),OY=w(),V9=OY.StripeResource.method;qY.Files=OY.StripeResource.extend({create:V9({method:"POST",fullPath:"/v1/files",headers:{"Content-Type":"multipart/form-data"},host:"files.stripe.com"}),retrieve:V9({method:"GET",fullPath:"/v1/files/{file}"}),list:V9({method:"GET",fullPath:"/v1/files",methodType:"list"}),requestDataProcessor:$z.multipartRequestDataProcessor})});var NY=K((kY)=>{Object.defineProperty(kY,"__esModule",{value:!0});kY.InvoiceItems=void 0;var CY=w(),t0=CY.StripeResource.method;kY.InvoiceItems=CY.StripeResource.extend({create:t0({method:"POST",fullPath:"/v1/invoiceitems",requestSchema:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}},quantity_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}},responseSchema:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"decimal_string"}}}}),retrieve:t0({method:"GET",fullPath:"/v1/invoiceitems/{invoiceitem}",responseSchema:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"decimal_string"}}}}),update:t0({method:"POST",fullPath:"/v1/invoiceitems/{invoiceitem}",requestSchema:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}},quantity_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}},responseSchema:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"decimal_string"}}}}),list:t0({method:"GET",fullPath:"/v1/invoiceitems",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"decimal_string"}}}}}}}),del:t0({method:"DELETE",fullPath:"/v1/invoiceitems/{invoiceitem}"})})});var RY=K((PY)=>{Object.defineProperty(PY,"__esModule",{value:!0});PY.InvoicePayments=void 0;var IY=w(),xY=IY.StripeResource.method;PY.InvoicePayments=IY.StripeResource.extend({retrieve:xY({method:"GET",fullPath:"/v1/invoice_payments/{invoice_payment}"}),list:xY({method:"GET",fullPath:"/v1/invoice_payments",methodType:"list"})})});var jY=K((yY)=>{Object.defineProperty(yY,"__esModule",{value:!0});yY.InvoiceRenderingTemplates=void 0;var vY=w(),d8=vY.StripeResource.method;yY.InvoiceRenderingTemplates=vY.StripeResource.extend({retrieve:d8({method:"GET",fullPath:"/v1/invoice_rendering_templates/{template}"}),list:d8({method:"GET",fullPath:"/v1/invoice_rendering_templates",methodType:"list"}),archive:d8({method:"POST",fullPath:"/v1/invoice_rendering_templates/{template}/archive"}),unarchive:d8({method:"POST",fullPath:"/v1/invoice_rendering_templates/{template}/unarchive"})})});var gY=K((MY)=>{Object.defineProperty(MY,"__esModule",{value:!0});MY.Invoices=void 0;var fY=w(),S=fY.StripeResource.method;MY.Invoices=fY.StripeResource.extend({create:S({method:"POST",fullPath:"/v1/invoices",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),retrieve:S({method:"GET",fullPath:"/v1/invoices/{invoice}",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),update:S({method:"POST",fullPath:"/v1/invoices/{invoice}",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),list:S({method:"GET",fullPath:"/v1/invoices",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),del:S({method:"DELETE",fullPath:"/v1/invoices/{invoice}"}),addLines:S({method:"POST",fullPath:"/v1/invoices/{invoice}/add_lines",requestSchema:{kind:"object",fields:{lines:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}},quantity_decimal:{kind:"decimal_string"}}}}}},responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),attachPayment:S({method:"POST",fullPath:"/v1/invoices/{invoice}/attach_payment",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),createPreview:S({method:"POST",fullPath:"/v1/invoices/create_preview",requestSchema:{kind:"object",fields:{invoice_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}},quantity_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}}},schedule_details:{kind:"object",fields:{phases:{kind:"array",element:{kind:"object",fields:{add_invoice_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}}}}},subscription_details:{kind:"object",fields:{items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}}}},responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),finalizeInvoice:S({method:"POST",fullPath:"/v1/invoices/{invoice}/finalize",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),listLineItems:S({method:"GET",fullPath:"/v1/invoices/{invoice}/lines",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),markUncollectible:S({method:"POST",fullPath:"/v1/invoices/{invoice}/mark_uncollectible",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),pay:S({method:"POST",fullPath:"/v1/invoices/{invoice}/pay",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),removeLines:S({method:"POST",fullPath:"/v1/invoices/{invoice}/remove_lines",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),search:S({method:"GET",fullPath:"/v1/invoices/search",methodType:"search",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),sendInvoice:S({method:"POST",fullPath:"/v1/invoices/{invoice}/send",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),updateLines:S({method:"POST",fullPath:"/v1/invoices/{invoice}/update_lines",requestSchema:{kind:"object",fields:{lines:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}},quantity_decimal:{kind:"decimal_string"}}}}}},responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),updateLineItem:S({method:"POST",fullPath:"/v1/invoices/{invoice}/lines/{line_item_id}",requestSchema:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}},quantity_decimal:{kind:"decimal_string"}}},responseSchema:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}),voidInvoice:S({method:"POST",fullPath:"/v1/invoices/{invoice}/void",responseSchema:{kind:"object",fields:{lines:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{pricing:{kind:"nullable",inner:{kind:"object",fields:{unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},quantity_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}})})});var cY=K((mY)=>{Object.defineProperty(mY,"__esModule",{value:!0});mY.Mandates=void 0;var hY=w(),Zz=hY.StripeResource.method;mY.Mandates=hY.StripeResource.extend({retrieve:Zz({method:"GET",fullPath:"/v1/mandates/{mandate}"})})});var iY=K((pY)=>{Object.defineProperty(pY,"__esModule",{value:!0});pY.OAuth=void 0;var lY=w(),Jz=c(),nY=lY.StripeResource.method,B9="connect.stripe.com";pY.OAuth=lY.StripeResource.extend({basePath:"/",authorizeUrl($,Z){$=$||{},Z=Z||{};let J="oauth/authorize";if(Z.express)J=`express/${J}`;if(!$.response_type)$.response_type="code";if(!$.client_id)$.client_id=this._stripe.getClientId();if(!$.scope)$.scope="read_write";return`https://${B9}/${J}?${(0,Jz.queryStringifyRequestData)($)}`},token:nY({method:"POST",path:"oauth/token",host:B9}),deauthorize($,...Z){if(!$.client_id)$.client_id=this._stripe.getClientId();return nY({method:"POST",path:"oauth/deauthorize",host:B9}).apply(this,[$,...Z])}})});var tY=K((sY)=>{Object.defineProperty(sY,"__esModule",{value:!0});sY.PaymentAttemptRecords=void 0;var oY=w(),aY=oY.StripeResource.method;sY.PaymentAttemptRecords=oY.StripeResource.extend({retrieve:aY({method:"GET",fullPath:"/v1/payment_attempt_records/{id}"}),list:aY({method:"GET",fullPath:"/v1/payment_attempt_records",methodType:"list"})})});var JG=K(($G)=>{Object.defineProperty($G,"__esModule",{value:!0});$G.PaymentIntents=void 0;var eY=w(),g=eY.StripeResource.method;$G.PaymentIntents=eY.StripeResource.extend({create:g({method:"POST",fullPath:"/v1/payment_intents"}),retrieve:g({method:"GET",fullPath:"/v1/payment_intents/{intent}"}),update:g({method:"POST",fullPath:"/v1/payment_intents/{intent}"}),list:g({method:"GET",fullPath:"/v1/payment_intents",methodType:"list"}),applyCustomerBalance:g({method:"POST",fullPath:"/v1/payment_intents/{intent}/apply_customer_balance"}),cancel:g({method:"POST",fullPath:"/v1/payment_intents/{intent}/cancel"}),capture:g({method:"POST",fullPath:"/v1/payment_intents/{intent}/capture"}),confirm:g({method:"POST",fullPath:"/v1/payment_intents/{intent}/confirm"}),incrementAuthorization:g({method:"POST",fullPath:"/v1/payment_intents/{intent}/increment_authorization"}),listAmountDetailsLineItems:g({method:"GET",fullPath:"/v1/payment_intents/{intent}/amount_details_line_items",methodType:"list"}),search:g({method:"GET",fullPath:"/v1/payment_intents/search",methodType:"search"}),verifyMicrodeposits:g({method:"POST",fullPath:"/v1/payment_intents/{intent}/verify_microdeposits"})})});var GG=K((XG)=>{Object.defineProperty(XG,"__esModule",{value:!0});XG.PaymentLinks=void 0;var QG=w(),e0=QG.StripeResource.method;XG.PaymentLinks=QG.StripeResource.extend({create:e0({method:"POST",fullPath:"/v1/payment_links",requestSchema:{kind:"object",fields:{line_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),retrieve:e0({method:"GET",fullPath:"/v1/payment_links/{payment_link}",responseSchema:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),update:e0({method:"POST",fullPath:"/v1/payment_links/{payment_link}",responseSchema:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}),list:e0({method:"GET",fullPath:"/v1/payment_links",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}),listLineItems:e0({method:"GET",fullPath:"/v1/payment_links/{payment_link}/line_items",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}})})});var UG=K((BG)=>{Object.defineProperty(BG,"__esModule",{value:!0});BG.PaymentMethodConfigurations=void 0;var VG=w(),i8=VG.StripeResource.method;BG.PaymentMethodConfigurations=VG.StripeResource.extend({create:i8({method:"POST",fullPath:"/v1/payment_method_configurations"}),retrieve:i8({method:"GET",fullPath:"/v1/payment_method_configurations/{configuration}"}),update:i8({method:"POST",fullPath:"/v1/payment_method_configurations/{configuration}"}),list:i8({method:"GET",fullPath:"/v1/payment_method_configurations",methodType:"list"})})});var HG=K((LG)=>{Object.defineProperty(LG,"__esModule",{value:!0});LG.PaymentMethodDomains=void 0;var zG=w(),$8=zG.StripeResource.method;LG.PaymentMethodDomains=zG.StripeResource.extend({create:$8({method:"POST",fullPath:"/v1/payment_method_domains"}),retrieve:$8({method:"GET",fullPath:"/v1/payment_method_domains/{payment_method_domain}"}),update:$8({method:"POST",fullPath:"/v1/payment_method_domains/{payment_method_domain}"}),list:$8({method:"GET",fullPath:"/v1/payment_method_domains",methodType:"list"}),validate:$8({method:"POST",fullPath:"/v1/payment_method_domains/{payment_method_domain}/validate"})})});var OG=K((TG)=>{Object.defineProperty(TG,"__esModule",{value:!0});TG.PaymentMethods=void 0;var wG=w(),k0=wG.StripeResource.method;TG.PaymentMethods=wG.StripeResource.extend({create:k0({method:"POST",fullPath:"/v1/payment_methods"}),retrieve:k0({method:"GET",fullPath:"/v1/payment_methods/{payment_method}"}),update:k0({method:"POST",fullPath:"/v1/payment_methods/{payment_method}"}),list:k0({method:"GET",fullPath:"/v1/payment_methods",methodType:"list"}),attach:k0({method:"POST",fullPath:"/v1/payment_methods/{payment_method}/attach"}),detach:k0({method:"POST",fullPath:"/v1/payment_methods/{payment_method}/detach"})})});var CG=K((EG)=>{Object.defineProperty(EG,"__esModule",{value:!0});EG.PaymentRecords=void 0;var qG=w(),t=qG.StripeResource.method;EG.PaymentRecords=qG.StripeResource.extend({retrieve:t({method:"GET",fullPath:"/v1/payment_records/{id}"}),reportPayment:t({method:"POST",fullPath:"/v1/payment_records/report_payment"}),reportPaymentAttempt:t({method:"POST",fullPath:"/v1/payment_records/{id}/report_payment_attempt"}),reportPaymentAttemptCanceled:t({method:"POST",fullPath:"/v1/payment_records/{id}/report_payment_attempt_canceled"}),reportPaymentAttemptFailed:t({method:"POST",fullPath:"/v1/payment_records/{id}/report_payment_attempt_failed"}),reportPaymentAttemptGuaranteed:t({method:"POST",fullPath:"/v1/payment_records/{id}/report_payment_attempt_guaranteed"}),reportPaymentAttemptInformational:t({method:"POST",fullPath:"/v1/payment_records/{id}/report_payment_attempt_informational"}),reportRefund:t({method:"POST",fullPath:"/v1/payment_records/{id}/report_refund"})})});var xG=K((AG)=>{Object.defineProperty(AG,"__esModule",{value:!0});AG.Payouts=void 0;var kG=w(),A0=kG.StripeResource.method;AG.Payouts=kG.StripeResource.extend({create:A0({method:"POST",fullPath:"/v1/payouts"}),retrieve:A0({method:"GET",fullPath:"/v1/payouts/{payout}"}),update:A0({method:"POST",fullPath:"/v1/payouts/{payout}"}),list:A0({method:"GET",fullPath:"/v1/payouts",methodType:"list"}),cancel:A0({method:"POST",fullPath:"/v1/payouts/{payout}/cancel"}),reverse:A0({method:"POST",fullPath:"/v1/payouts/{payout}/reverse"})})});var RG=K((PG)=>{Object.defineProperty(PG,"__esModule",{value:!0});PG.Plans=void 0;var IG=w(),Z8=IG.StripeResource.method;PG.Plans=IG.StripeResource.extend({create:Z8({method:"POST",fullPath:"/v1/plans",requestSchema:{kind:"object",fields:{amount_decimal:{kind:"decimal_string"},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}}}}},responseSchema:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),retrieve:Z8({method:"GET",fullPath:"/v1/plans/{plan}",responseSchema:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),update:Z8({method:"POST",fullPath:"/v1/plans/{plan}",responseSchema:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),list:Z8({method:"GET",fullPath:"/v1/plans",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}),del:Z8({method:"DELETE",fullPath:"/v1/plans/{plan}"})})});var jG=K((yG)=>{Object.defineProperty(yG,"__esModule",{value:!0});yG.Prices=void 0;var vG=w(),J8=vG.StripeResource.method;yG.Prices=vG.StripeResource.extend({create:J8({method:"POST",fullPath:"/v1/prices",requestSchema:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}}},unit_amount_decimal:{kind:"decimal_string"}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}}},unit_amount_decimal:{kind:"decimal_string"}}},responseSchema:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}),retrieve:J8({method:"GET",fullPath:"/v1/prices/{price}",responseSchema:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}),update:J8({method:"POST",fullPath:"/v1/prices/{price}",responseSchema:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}),list:J8({method:"GET",fullPath:"/v1/prices",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}),search:J8({method:"GET",fullPath:"/v1/prices/search",methodType:"search",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}})})});var gG=K((MG)=>{Object.defineProperty(MG,"__esModule",{value:!0});MG.Products=void 0;var fG=w(),n=fG.StripeResource.method;MG.Products=fG.StripeResource.extend({create:n({method:"POST",fullPath:"/v1/products",requestSchema:{kind:"object",fields:{default_price_data:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"decimal_string"},unit_amount_decimal:{kind:"decimal_string"}}}},unit_amount_decimal:{kind:"decimal_string"}}}},unit_amount_decimal:{kind:"decimal_string"}}}}}}),retrieve:n({method:"GET",fullPath:"/v1/products/{id}"}),update:n({method:"POST",fullPath:"/v1/products/{id}"}),list:n({method:"GET",fullPath:"/v1/products",methodType:"list"}),del:n({method:"DELETE",fullPath:"/v1/products/{id}"}),createFeature:n({method:"POST",fullPath:"/v1/products/{product}/features"}),deleteFeature:n({method:"DELETE",fullPath:"/v1/products/{product}/features/{id}"}),listFeatures:n({method:"GET",fullPath:"/v1/products/{product}/features",methodType:"list"}),retrieveFeature:n({method:"GET",fullPath:"/v1/products/{product}/features/{id}"}),search:n({method:"GET",fullPath:"/v1/products/search",methodType:"search"})})});var cG=K((mG)=>{Object.defineProperty(mG,"__esModule",{value:!0});mG.PromotionCodes=void 0;var hG=w(),a8=hG.StripeResource.method;mG.PromotionCodes=hG.StripeResource.extend({create:a8({method:"POST",fullPath:"/v1/promotion_codes"}),retrieve:a8({method:"GET",fullPath:"/v1/promotion_codes/{promotion_code}"}),update:a8({method:"POST",fullPath:"/v1/promotion_codes/{promotion_code}"}),list:a8({method:"GET",fullPath:"/v1/promotion_codes",methodType:"list"})})});var dG=K((lG)=>{Object.defineProperty(lG,"__esModule",{value:!0});lG.Quotes=void 0;var nG=w(),l=nG.StripeResource.method;lG.Quotes=nG.StripeResource.extend({create:l({method:"POST",fullPath:"/v1/quotes",requestSchema:{kind:"object",fields:{line_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}),retrieve:l({method:"GET",fullPath:"/v1/quotes/{quote}",responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}),update:l({method:"POST",fullPath:"/v1/quotes/{quote}",requestSchema:{kind:"object",fields:{line_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}),list:l({method:"GET",fullPath:"/v1/quotes",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}}}}),accept:l({method:"POST",fullPath:"/v1/quotes/{quote}/accept",responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}),cancel:l({method:"POST",fullPath:"/v1/quotes/{quote}/cancel",responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}),finalizeQuote:l({method:"POST",fullPath:"/v1/quotes/{quote}/finalize",responseSchema:{kind:"object",fields:{computed:{kind:"object",fields:{upfront:{kind:"object",fields:{line_items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}}}),listComputedUpfrontLineItems:l({method:"GET",fullPath:"/v1/quotes/{quote}/computed_upfront_line_items",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}),listLineItems:l({method:"GET",fullPath:"/v1/quotes/{quote}/line_items",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{price:{kind:"nullable",inner:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}),pdf:l({method:"GET",fullPath:"/v1/quotes/{quote}/pdf",host:"files.stripe.com",streaming:!0})})});var sG=K((aG)=>{Object.defineProperty(aG,"__esModule",{value:!0});aG.Refunds=void 0;var iG=w(),Q8=iG.StripeResource.method;aG.Refunds=iG.StripeResource.extend({create:Q8({method:"POST",fullPath:"/v1/refunds"}),retrieve:Q8({method:"GET",fullPath:"/v1/refunds/{refund}"}),update:Q8({method:"POST",fullPath:"/v1/refunds/{refund}"}),list:Q8({method:"GET",fullPath:"/v1/refunds",methodType:"list"}),cancel:Q8({method:"POST",fullPath:"/v1/refunds/{refund}/cancel"})})});var $V=K((tG)=>{Object.defineProperty(tG,"__esModule",{value:!0});tG.Reviews=void 0;var rG=w(),W9=rG.StripeResource.method;tG.Reviews=rG.StripeResource.extend({retrieve:W9({method:"GET",fullPath:"/v1/reviews/{review}"}),list:W9({method:"GET",fullPath:"/v1/reviews",methodType:"list"}),approve:W9({method:"POST",fullPath:"/v1/reviews/{review}/approve"})})});var XV=K((JV)=>{Object.defineProperty(JV,"__esModule",{value:!0});JV.SetupAttempts=void 0;var ZV=w(),Qz=ZV.StripeResource.method;JV.SetupAttempts=ZV.StripeResource.extend({list:Qz({method:"GET",fullPath:"/v1/setup_attempts",methodType:"list"})})});var BV=K((GV)=>{Object.defineProperty(GV,"__esModule",{value:!0});GV.SetupIntents=void 0;var YV=w(),V0=YV.StripeResource.method;GV.SetupIntents=YV.StripeResource.extend({create:V0({method:"POST",fullPath:"/v1/setup_intents"}),retrieve:V0({method:"GET",fullPath:"/v1/setup_intents/{intent}"}),update:V0({method:"POST",fullPath:"/v1/setup_intents/{intent}"}),list:V0({method:"GET",fullPath:"/v1/setup_intents",methodType:"list"}),cancel:V0({method:"POST",fullPath:"/v1/setup_intents/{intent}/cancel"}),confirm:V0({method:"POST",fullPath:"/v1/setup_intents/{intent}/confirm"}),verifyMicrodeposits:V0({method:"POST",fullPath:"/v1/setup_intents/{intent}/verify_microdeposits"})})});var LV=K((UV)=>{Object.defineProperty(UV,"__esModule",{value:!0});UV.ShippingRates=void 0;var WV=w(),o8=WV.StripeResource.method;UV.ShippingRates=WV.StripeResource.extend({create:o8({method:"POST",fullPath:"/v1/shipping_rates"}),retrieve:o8({method:"GET",fullPath:"/v1/shipping_rates/{shipping_rate_token}"}),update:o8({method:"POST",fullPath:"/v1/shipping_rates/{shipping_rate_token}"}),list:o8({method:"GET",fullPath:"/v1/shipping_rates",methodType:"list"})})});var TV=K((HV)=>{Object.defineProperty(HV,"__esModule",{value:!0});HV.Sources=void 0;var KV=w(),X8=KV.StripeResource.method;HV.Sources=KV.StripeResource.extend({create:X8({method:"POST",fullPath:"/v1/sources"}),retrieve:X8({method:"GET",fullPath:"/v1/sources/{source}"}),update:X8({method:"POST",fullPath:"/v1/sources/{source}"}),listSourceTransactions:X8({method:"GET",fullPath:"/v1/sources/{source}/source_transactions",methodType:"list"}),verify:X8({method:"POST",fullPath:"/v1/sources/{source}/verify"})})});var EV=K((OV)=>{Object.defineProperty(OV,"__esModule",{value:!0});OV.SubscriptionItems=void 0;var DV=w(),Y8=DV.StripeResource.method;OV.SubscriptionItems=DV.StripeResource.extend({create:Y8({method:"POST",fullPath:"/v1/subscription_items",requestSchema:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}},responseSchema:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}),retrieve:Y8({method:"GET",fullPath:"/v1/subscription_items/{item}",responseSchema:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}),update:Y8({method:"POST",fullPath:"/v1/subscription_items/{item}",requestSchema:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}},responseSchema:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}),list:Y8({method:"GET",fullPath:"/v1/subscription_items",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}),del:Y8({method:"DELETE",fullPath:"/v1/subscription_items/{item}"})})});var AV=K((CV)=>{Object.defineProperty(CV,"__esModule",{value:!0});CV.SubscriptionSchedules=void 0;var FV=w(),N0=FV.StripeResource.method;CV.SubscriptionSchedules=FV.StripeResource.extend({create:N0({method:"POST",fullPath:"/v1/subscription_schedules",requestSchema:{kind:"object",fields:{phases:{kind:"array",element:{kind:"object",fields:{add_invoice_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}}}}}}),retrieve:N0({method:"GET",fullPath:"/v1/subscription_schedules/{schedule}"}),update:N0({method:"POST",fullPath:"/v1/subscription_schedules/{schedule}",requestSchema:{kind:"object",fields:{phases:{kind:"array",element:{kind:"object",fields:{add_invoice_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}}}}}}),list:N0({method:"GET",fullPath:"/v1/subscription_schedules",methodType:"list"}),cancel:N0({method:"POST",fullPath:"/v1/subscription_schedules/{schedule}/cancel"}),release:N0({method:"POST",fullPath:"/v1/subscription_schedules/{schedule}/release"})})});var PV=K((xV)=>{Object.defineProperty(xV,"__esModule",{value:!0});xV.Subscriptions=void 0;var NV=w(),i=NV.StripeResource.method;xV.Subscriptions=NV.StripeResource.extend({create:i({method:"POST",fullPath:"/v1/subscriptions",requestSchema:{kind:"object",fields:{add_invoice_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}),retrieve:i({method:"GET",fullPath:"/v1/subscriptions/{subscription_exposed_id}",responseSchema:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}),update:i({method:"POST",fullPath:"/v1/subscriptions/{subscription_exposed_id}",requestSchema:{kind:"object",fields:{add_invoice_items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}},items:{kind:"array",element:{kind:"object",fields:{price_data:{kind:"object",fields:{unit_amount_decimal:{kind:"decimal_string"}}}}}}}},responseSchema:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}),list:i({method:"GET",fullPath:"/v1/subscriptions",methodType:"list",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}}),cancel:i({method:"DELETE",fullPath:"/v1/subscriptions/{subscription_exposed_id}",responseSchema:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}),deleteDiscount:i({method:"DELETE",fullPath:"/v1/subscriptions/{subscription_exposed_id}/discount"}),migrate:i({method:"POST",fullPath:"/v1/subscriptions/{subscription}/migrate",responseSchema:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}),resume:i({method:"POST",fullPath:"/v1/subscriptions/{subscription}/resume",responseSchema:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}),search:i({method:"GET",fullPath:"/v1/subscriptions/search",methodType:"search",responseSchema:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{items:{kind:"object",fields:{data:{kind:"array",element:{kind:"object",fields:{plan:{kind:"object",fields:{amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}},price:{kind:"object",fields:{currency_options:{kind:"array",element:{kind:"object",fields:{tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},tiers:{kind:"array",element:{kind:"object",fields:{flat_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}},unit_amount_decimal:{kind:"nullable",inner:{kind:"decimal_string"}}}}}}}}}}}}}}})})});var bV=K((vV)=>{Object.defineProperty(vV,"__esModule",{value:!0});vV.TaxCodes=void 0;var RV=w(),SV=RV.StripeResource.method;vV.TaxCodes=RV.StripeResource.extend({retrieve:SV({method:"GET",fullPath:"/v1/tax_codes/{id}"}),list:SV({method:"GET",fullPath:"/v1/tax_codes",methodType:"list"})})});var _V=K((fV)=>{Object.defineProperty(fV,"__esModule",{value:!0});fV.TaxIds=void 0;var jV=w(),s8=jV.StripeResource.method;fV.TaxIds=jV.StripeResource.extend({create:s8({method:"POST",fullPath:"/v1/tax_ids"}),retrieve:s8({method:"GET",fullPath:"/v1/tax_ids/{id}"}),list:s8({method:"GET",fullPath:"/v1/tax_ids",methodType:"list"}),del:s8({method:"DELETE",fullPath:"/v1/tax_ids/{id}"})})});var uV=K((hV)=>{Object.defineProperty(hV,"__esModule",{value:!0});hV.TaxRates=void 0;var gV=w(),r8=gV.StripeResource.method;hV.TaxRates=gV.StripeResource.extend({create:r8({method:"POST",fullPath:"/v1/tax_rates"}),retrieve:r8({method:"GET",fullPath:"/v1/tax_rates/{tax_rate}"}),update:r8({method:"POST",fullPath:"/v1/tax_rates/{tax_rate}"}),list:r8({method:"GET",fullPath:"/v1/tax_rates",methodType:"list"})})});var dV=K((lV)=>{Object.defineProperty(lV,"__esModule",{value:!0});lV.Tokens=void 0;var nV=w(),cV=nV.StripeResource.method;lV.Tokens=nV.StripeResource.extend({create:cV({method:"POST",fullPath:"/v1/tokens"}),retrieve:cV({method:"GET",fullPath:"/v1/tokens/{token}"})})});var sV=K((aV)=>{Object.defineProperty(aV,"__esModule",{value:!0});aV.Topups=void 0;var iV=w(),G8=iV.StripeResource.method;aV.Topups=iV.StripeResource.extend({create:G8({method:"POST",fullPath:"/v1/topups"}),retrieve:G8({method:"GET",fullPath:"/v1/topups/{topup}"}),update:G8({method:"POST",fullPath:"/v1/topups/{topup}"}),list:G8({method:"GET",fullPath:"/v1/topups",methodType:"list"}),cancel:G8({method:"POST",fullPath:"/v1/topups/{topup}/cancel"})})});var $3=K((tV)=>{Object.defineProperty(tV,"__esModule",{value:!0});tV.Transfers=void 0;var rV=w(),e=rV.StripeResource.method;tV.Transfers=rV.StripeResource.extend({create:e({method:"POST",fullPath:"/v1/transfers"}),retrieve:e({method:"GET",fullPath:"/v1/transfers/{transfer}"}),update:e({method:"POST",fullPath:"/v1/transfers/{transfer}"}),list:e({method:"GET",fullPath:"/v1/transfers",methodType:"list"}),createReversal:e({method:"POST",fullPath:"/v1/transfers/{id}/reversals"}),listReversals:e({method:"GET",fullPath:"/v1/transfers/{id}/reversals",methodType:"list"}),retrieveReversal:e({method:"GET",fullPath:"/v1/transfers/{transfer}/reversals/{id}"}),updateReversal:e({method:"POST",fullPath:"/v1/transfers/{transfer}/reversals/{id}"})})});var X3=K((J3)=>{Object.defineProperty(J3,"__esModule",{value:!0});J3.WebhookEndpoints=void 0;var Z3=w(),V8=Z3.StripeResource.method;J3.WebhookEndpoints=Z3.StripeResource.extend({create:V8({method:"POST",fullPath:"/v1/webhook_endpoints"}),retrieve:V8({method:"GET",fullPath:"/v1/webhook_endpoints/{webhook_endpoint}"}),update:V8({method:"POST",fullPath:"/v1/webhook_endpoints/{webhook_endpoint}"}),list:V8({method:"GET",fullPath:"/v1/webhook_endpoints",methodType:"list"}),del:V8({method:"DELETE",fullPath:"/v1/webhook_endpoints/{webhook_endpoint}"})})});var G3=K((E)=>{Object.defineProperty(E,"__esModule",{value:!0});E.Subscriptions=E.SubscriptionSchedules=E.SubscriptionItems=E.Sources=E.ShippingRates=E.SetupIntents=E.SetupAttempts=E.Reviews=E.Refunds=E.Quotes=E.PromotionCodes=E.Products=E.Prices=E.Plans=E.Payouts=E.PaymentRecords=E.PaymentMethods=E.PaymentMethodDomains=E.PaymentMethodConfigurations=E.PaymentLinks=E.PaymentIntents=E.PaymentAttemptRecords=E.OAuth=E.Mandates=E.Invoices=E.InvoiceRenderingTemplates=E.InvoicePayments=E.InvoiceItems=E.Files=E.FileLinks=E.ExchangeRates=E.Events=E.EphemeralKeys=E.Disputes=E.Customers=E.CustomerSessions=E.CreditNotes=E.Coupons=E.CountrySpecs=E.ConfirmationTokens=E.Charges=E.BalanceTransactions=E.BalanceSettings=E.Balance=E.ApplicationFees=E.ApplePayDomains=E.Accounts=E.AccountSessions=E.AccountLinks=E.Account=void 0;E.V2=E.Treasury=E.TestHelpers=E.Terminal=E.Tax=E.Sigma=E.Reporting=E.Radar=E.Issuing=E.Identity=E.Forwarding=E.FinancialConnections=E.Entitlements=E.Climate=E.Checkout=E.BillingPortal=E.Billing=E.Apps=E.WebhookEndpoints=E.Transfers=E.Topups=E.Tokens=E.TaxRates=E.TaxIds=E.TaxCodes=void 0;var x=w1(),Xz=q1(),Yz=A1(),Gz=P1(),Vz=m1(),Bz=p1(),Wz=o1(),Uz=e1(),zz=Q4(),Lz=V4(),Kz=z4(),Hz=w4(),wz=q4(),Tz=k4(),Dz=I4(),Oz=v4(),qz=f4(),Ez=h4(),Fz=n4(),Cz=a4(),kz=t4(),Az=J6(),Nz=G6(),xz=U6(),Iz=H6(),Pz=q6(),Sz=k6(),Rz=I6(),vz=v6(),yz=f6(),bz=h6(),jz=n6(),fz=i6(),Mz=r6(),_z=Z7(),gz=Y7(),hz=W7(),mz=K7(),uz=D7(),cz=F7(),nz=N7(),lz=S7(),pz=b7(),dz=_7(),iz=u7(),az=p7(),oz=o7(),sz=e7(),rz=QJ(),tz=BJ(),ez=KJ(),$L=DJ(),ZL=FJ(),JL=NJ(),QL=RJ(),XL=jJ(),YL=hJ(),GL=nJ(),VL=iJ(),BL=rJ(),WL=J5(),UL=G5(),zL=z5(),LL=w5(),KL=q5(),HL=k5(),wL=P5(),TL=b5(),DL=g5(),OL=c5(),qL=d5(),EL=r5(),FL=JQ(),CL=GQ(),kL=UQ(),AL=HQ(),NL=qQ(),xL=kQ(),IL=IQ(),PL=yQ(),SL=MQ(),RL=G9();Object.defineProperty(E,"Account",{enumerable:!0,get:function(){return RL.Accounts}});var vL=nQ();Object.defineProperty(E,"AccountLinks",{enumerable:!0,get:function(){return vL.AccountLinks}});var yL=iQ();Object.defineProperty(E,"AccountSessions",{enumerable:!0,get:function(){return yL.AccountSessions}});var bL=G9();Object.defineProperty(E,"Accounts",{enumerable:!0,get:function(){return bL.Accounts}});var jL=rQ();Object.defineProperty(E,"ApplePayDomains",{enumerable:!0,get:function(){return jL.ApplePayDomains}});var fL=ZX();Object.defineProperty(E,"ApplicationFees",{enumerable:!0,get:function(){return fL.ApplicationFees}});var ML=YX();Object.defineProperty(E,"Balance",{enumerable:!0,get:function(){return ML.Balance}});var _L=UX();Object.defineProperty(E,"BalanceSettings",{enumerable:!0,get:function(){return _L.BalanceSettings}});var gL=wX();Object.defineProperty(E,"BalanceTransactions",{enumerable:!0,get:function(){return gL.BalanceTransactions}});var hL=qX();Object.defineProperty(E,"Charges",{enumerable:!0,get:function(){return hL.Charges}});var mL=kX();Object.defineProperty(E,"ConfirmationTokens",{enumerable:!0,get:function(){return mL.ConfirmationTokens}});var uL=PX();Object.defineProperty(E,"CountrySpecs",{enumerable:!0,get:function(){return uL.CountrySpecs}});var cL=yX();Object.defineProperty(E,"Coupons",{enumerable:!0,get:function(){return cL.Coupons}});var nL=MX();Object.defineProperty(E,"CreditNotes",{enumerable:!0,get:function(){return nL.CreditNotes}});var lL=mX();Object.defineProperty(E,"CustomerSessions",{enumerable:!0,get:function(){return lL.CustomerSessions}});var pL=lX();Object.defineProperty(E,"Customers",{enumerable:!0,get:function(){return pL.Customers}});var dL=aX();Object.defineProperty(E,"Disputes",{enumerable:!0,get:function(){return dL.Disputes}});var iL=eX();Object.defineProperty(E,"EphemeralKeys",{enumerable:!0,get:function(){return iL.EphemeralKeys}});var aL=XY();Object.defineProperty(E,"Events",{enumerable:!0,get:function(){return aL.Events}});var oL=WY();Object.defineProperty(E,"ExchangeRates",{enumerable:!0,get:function(){return oL.ExchangeRates}});var sL=KY();Object.defineProperty(E,"FileLinks",{enumerable:!0,get:function(){return sL.FileLinks}});var rL=FY();Object.defineProperty(E,"Files",{enumerable:!0,get:function(){return rL.Files}});var tL=NY();Object.defineProperty(E,"InvoiceItems",{enumerable:!0,get:function(){return tL.InvoiceItems}});var eL=RY();Object.defineProperty(E,"InvoicePayments",{enumerable:!0,get:function(){return eL.InvoicePayments}});var $K=jY();Object.defineProperty(E,"InvoiceRenderingTemplates",{enumerable:!0,get:function(){return $K.InvoiceRenderingTemplates}});var ZK=gY();Object.defineProperty(E,"Invoices",{enumerable:!0,get:function(){return ZK.Invoices}});var JK=cY();Object.defineProperty(E,"Mandates",{enumerable:!0,get:function(){return JK.Mandates}});var QK=iY();Object.defineProperty(E,"OAuth",{enumerable:!0,get:function(){return QK.OAuth}});var XK=tY();Object.defineProperty(E,"PaymentAttemptRecords",{enumerable:!0,get:function(){return XK.PaymentAttemptRecords}});var YK=JG();Object.defineProperty(E,"PaymentIntents",{enumerable:!0,get:function(){return YK.PaymentIntents}});var GK=GG();Object.defineProperty(E,"PaymentLinks",{enumerable:!0,get:function(){return GK.PaymentLinks}});var VK=UG();Object.defineProperty(E,"PaymentMethodConfigurations",{enumerable:!0,get:function(){return VK.PaymentMethodConfigurations}});var BK=HG();Object.defineProperty(E,"PaymentMethodDomains",{enumerable:!0,get:function(){return BK.PaymentMethodDomains}});var WK=OG();Object.defineProperty(E,"PaymentMethods",{enumerable:!0,get:function(){return WK.PaymentMethods}});var UK=CG();Object.defineProperty(E,"PaymentRecords",{enumerable:!0,get:function(){return UK.PaymentRecords}});var zK=xG();Object.defineProperty(E,"Payouts",{enumerable:!0,get:function(){return zK.Payouts}});var LK=RG();Object.defineProperty(E,"Plans",{enumerable:!0,get:function(){return LK.Plans}});var KK=jG();Object.defineProperty(E,"Prices",{enumerable:!0,get:function(){return KK.Prices}});var HK=gG();Object.defineProperty(E,"Products",{enumerable:!0,get:function(){return HK.Products}});var wK=cG();Object.defineProperty(E,"PromotionCodes",{enumerable:!0,get:function(){return wK.PromotionCodes}});var TK=dG();Object.defineProperty(E,"Quotes",{enumerable:!0,get:function(){return TK.Quotes}});var DK=sG();Object.defineProperty(E,"Refunds",{enumerable:!0,get:function(){return DK.Refunds}});var OK=$V();Object.defineProperty(E,"Reviews",{enumerable:!0,get:function(){return OK.Reviews}});var qK=XV();Object.defineProperty(E,"SetupAttempts",{enumerable:!0,get:function(){return qK.SetupAttempts}});var EK=BV();Object.defineProperty(E,"SetupIntents",{enumerable:!0,get:function(){return EK.SetupIntents}});var FK=LV();Object.defineProperty(E,"ShippingRates",{enumerable:!0,get:function(){return FK.ShippingRates}});var CK=TV();Object.defineProperty(E,"Sources",{enumerable:!0,get:function(){return CK.Sources}});var kK=EV();Object.defineProperty(E,"SubscriptionItems",{enumerable:!0,get:function(){return kK.SubscriptionItems}});var AK=AV();Object.defineProperty(E,"SubscriptionSchedules",{enumerable:!0,get:function(){return AK.SubscriptionSchedules}});var NK=PV();Object.defineProperty(E,"Subscriptions",{enumerable:!0,get:function(){return NK.Subscriptions}});var xK=bV();Object.defineProperty(E,"TaxCodes",{enumerable:!0,get:function(){return xK.TaxCodes}});var IK=_V();Object.defineProperty(E,"TaxIds",{enumerable:!0,get:function(){return IK.TaxIds}});var PK=uV();Object.defineProperty(E,"TaxRates",{enumerable:!0,get:function(){return PK.TaxRates}});var SK=dV();Object.defineProperty(E,"Tokens",{enumerable:!0,get:function(){return SK.Tokens}});var RK=sV();Object.defineProperty(E,"Topups",{enumerable:!0,get:function(){return RK.Topups}});var vK=$3();Object.defineProperty(E,"Transfers",{enumerable:!0,get:function(){return vK.Transfers}});var yK=X3();Object.defineProperty(E,"WebhookEndpoints",{enumerable:!0,get:function(){return yK.WebhookEndpoints}});E.Apps=(0,x.resourceNamespace)("apps",{Secrets:LL.Secrets});E.Billing=(0,x.resourceNamespace)("billing",{Alerts:Wz.Alerts,CreditBalanceSummary:Fz.CreditBalanceSummary,CreditBalanceTransactions:Cz.CreditBalanceTransactions,CreditGrants:kz.CreditGrants,MeterEventAdjustments:Mz.MeterEventAdjustments,MeterEvents:mz.MeterEvents,Meters:cz.Meters});E.BillingPortal=(0,x.resourceNamespace)("billingPortal",{Configurations:Dz.Configurations,Sessions:KL.Sessions});E.Checkout=(0,x.resourceNamespace)("checkout",{Sessions:HL.Sessions});E.Climate=(0,x.resourceNamespace)("climate",{Orders:lz.Orders,Products:ez.Products,Suppliers:DL.Suppliers});E.Entitlements=(0,x.resourceNamespace)("entitlements",{ActiveEntitlements:Bz.ActiveEntitlements,Features:vz.Features});E.FinancialConnections=(0,x.resourceNamespace)("financialConnections",{Accounts:Gz.Accounts,Sessions:wL.Sessions,Transactions:FL.Transactions});E.Forwarding=(0,x.resourceNamespace)("forwarding",{Requests:UL.Requests});E.Identity=(0,x.resourceNamespace)("identity",{VerificationReports:PL.VerificationReports,VerificationSessions:SL.VerificationSessions});E.Issuing=(0,x.resourceNamespace)("issuing",{Authorizations:zz.Authorizations,Cardholders:Hz.Cardholders,Cards:wz.Cards,Disputes:Iz.Disputes,PersonalizationDesigns:sz.PersonalizationDesigns,PhysicalBundles:tz.PhysicalBundles,Tokens:qL.Tokens,Transactions:CL.Transactions});E.Radar=(0,x.resourceNamespace)("radar",{EarlyFraudWarnings:Pz.EarlyFraudWarnings,PaymentEvaluations:oz.PaymentEvaluations,ValueListItems:xL.ValueListItems,ValueLists:IL.ValueLists});E.Reporting=(0,x.resourceNamespace)("reporting",{ReportRuns:BL.ReportRuns,ReportTypes:WL.ReportTypes});E.Sigma=(0,x.resourceNamespace)("sigma",{ScheduledQueryRuns:zL.ScheduledQueryRuns});E.Tax=(0,x.resourceNamespace)("tax",{Associations:Uz.Associations,Calculations:Kz.Calculations,Registrations:VL.Registrations,Settings:TL.Settings,Transactions:kL.Transactions});E.Terminal=(0,x.resourceNamespace)("terminal",{Configurations:Oz.Configurations,ConnectionTokens:Ez.ConnectionTokens,Locations:fz.Locations,OnboardingLinks:nz.OnboardingLinks,Readers:$L.Readers});E.TestHelpers=(0,x.resourceNamespace)("testHelpers",{ConfirmationTokens:qz.ConfirmationTokens,Customers:Nz.Customers,Refunds:GL.Refunds,TestClocks:OL.TestClocks,Issuing:(0,x.resourceNamespace)("issuing",{Authorizations:Lz.Authorizations,Cards:Tz.Cards,PersonalizationDesigns:rz.PersonalizationDesigns,Transactions:AL.Transactions}),Terminal:(0,x.resourceNamespace)("terminal",{Readers:ZL.Readers}),Treasury:(0,x.resourceNamespace)("treasury",{InboundTransfers:bz.InboundTransfers,OutboundPayments:pz.OutboundPayments,OutboundTransfers:iz.OutboundTransfers,ReceivedCredits:JL.ReceivedCredits,ReceivedDebits:XL.ReceivedDebits})});E.Treasury=(0,x.resourceNamespace)("treasury",{CreditReversals:Az.CreditReversals,DebitReversals:xz.DebitReversals,FinancialAccounts:yz.FinancialAccounts,InboundTransfers:jz.InboundTransfers,OutboundPayments:dz.OutboundPayments,OutboundTransfers:az.OutboundTransfers,ReceivedCredits:QL.ReceivedCredits,ReceivedDebits:YL.ReceivedDebits,TransactionEntries:EL.TransactionEntries,Transactions:NL.Transactions});E.V2=(0,x.resourceNamespace)("v2",{Billing:(0,x.resourceNamespace)("billing",{MeterEventAdjustments:_z.MeterEventAdjustments,MeterEventSession:gz.MeterEventSession,MeterEventStream:hz.MeterEventStream,MeterEvents:uz.MeterEvents}),Core:(0,x.resourceNamespace)("core",{AccountLinks:Xz.AccountLinks,AccountTokens:Yz.AccountTokens,Accounts:Vz.Accounts,EventDestinations:Sz.EventDestinations,Events:Rz.Events})})});var C3=K((E3)=>{Object.defineProperty(E3,"__esModule",{value:!0});E3.createStripe=void 0;var V3=M0(),rK=hZ(),O3=w(),B3=G1(),tK=W1(),q3=L1(),eK=b0(),$H=I8(),W3=j0(),t8=G3(),B0=c(),U3="api.stripe.com",z3="443",L3="/v1/",K3=q3.ApiVersion,H3=80000,w3=5,T3=0.5,ZH=["name","version","url","partner_id"],D3=["authenticator","apiVersion","typescript","maxNetworkRetries","httpAgent","httpClient","timeout","host","port","protocol","telemetry","appInfo","stripeAccount","stripeContext"],JH=($)=>new rK.RequestSender($,O3.StripeResource.MAX_BUFFERED_REQUEST_METRICS);function QH($,Z=JH){Q.PACKAGE_VERSION="21.0.1",Q.API_VERSION=q3.ApiVersion;let J=typeof process<"u"&&process.env?(0,B0.detectAIAgent)(process.env):"";Q.AI_AGENT=J,Q.USER_AGENT={bindings_version:Q.PACKAGE_VERSION,lang:"node",typescript:!1,...(0,B0.determineProcessUserAgentProperties)(),...J?{ai_agent:J}:{}},Q.StripeResource=O3.StripeResource,Q.StripeContext=B3.StripeContext,Q.resources=t8,Q.HttpClient=W3.HttpClient,Q.HttpClientResponse=W3.HttpClientResponse,Q.CryptoProvider=eK.CryptoProvider,Q.webhooks=(0,tK.createWebhooks)($),Q.Decimal=$H.Decimal;function Q(X,Y={}){if(!(this instanceof Q))return new Q(X,Y);let G=this._getPropsFromConfig(Y);this._platformFunctions=$,Object.defineProperty(this,"_emitter",{value:this._platformFunctions.createEmitter(),enumerable:!1,configurable:!1,writable:!1}),this.VERSION=Q.PACKAGE_VERSION,this.on=this._emitter.on.bind(this._emitter),this.once=this._emitter.once.bind(this._emitter),this.off=this._emitter.removeListener.bind(this._emitter);let V=G.httpAgent||null;this._api={host:G.host||U3,port:G.port||z3,protocol:G.protocol||"https",basePath:L3,version:G.apiVersion||K3,timeout:(0,B0.validateInteger)("timeout",G.timeout,H3),maxNetworkRetries:(0,B0.validateInteger)("maxNetworkRetries",G.maxNetworkRetries,2),agent:V,httpClient:G.httpClient||(V?this._platformFunctions.createNodeHttpClient(V):this._platformFunctions.createDefaultHttpClient()),dev:!1,stripeAccount:G.stripeAccount||null,stripeContext:G.stripeContext||null};let U=G.typescript||!1;if(U!==Q.USER_AGENT.typescript)Q.USER_AGENT.typescript=U;if(G.appInfo)this._setAppInfo(G.appInfo);this._prepResources(),this._setAuthenticator(X,G.authenticator),this.errors=V3,this.webhooks=Q.webhooks,this._prevRequestMetrics=[],this._enableTelemetry=G.telemetry!==!1,this._requestSender=Z(this),this.StripeResource=Q.StripeResource,this.Decimal=Q.Decimal}return Q.errors=V3,Q.createNodeHttpClient=$.createNodeHttpClient,Q.createFetchHttpClient=$.createFetchHttpClient,Q.createNodeCryptoProvider=$.createNodeCryptoProvider,Q.createSubtleCryptoProvider=$.createSubtleCryptoProvider,Q.prototype={_appInfo:void 0,on:null,off:null,once:null,VERSION:null,StripeResource:null,webhooks:null,errors:null,_api:null,_prevRequestMetrics:null,_emitter:null,_enableTelemetry:null,_requestSender:null,_platformFunctions:null,rawRequest(X,Y,G,V){return this._requestSender._rawRequest(X,Y,G,V)},_setAuthenticator(X,Y){if(X&&Y)throw Error("Can't specify both apiKey and authenticator");if(!X&&!Y)throw Error("Neither apiKey nor config.authenticator provided");this._authenticator=X?(0,B0.createApiKeyAuthenticator)(X):Y},_setAppInfo(X){if(X&&typeof X!=="object")throw Error("AppInfo must be an object.");if(X&&!X.name)throw Error("AppInfo.name is required");X=X||{},this._appInfo=ZH.reduce((Y,G)=>{if(typeof X[G]=="string")Y=Y||{},Y[G]=X[G];return Y},{})},_setApiField(X,Y){this._api[X]=Y},getApiField(X){return this._api[X]},setClientId(X){this._clientId=X},getClientId(){return this._clientId},getConstant:(X)=>{switch(X){case"DEFAULT_HOST":return U3;case"DEFAULT_PORT":return z3;case"DEFAULT_BASE_PATH":return L3;case"DEFAULT_API_VERSION":return K3;case"DEFAULT_TIMEOUT":return H3;case"MAX_NETWORK_RETRY_DELAY_SEC":return w3;case"INITIAL_NETWORK_RETRY_DELAY_SEC":return T3}return Q[X]},getMaxNetworkRetries(){return this.getApiField("maxNetworkRetries")},_setApiNumberField(X,Y,G){let V=(0,B0.validateInteger)(X,Y,G);this._setApiField(X,V)},getMaxNetworkRetryDelay(){return w3},getInitialNetworkRetryDelay(){return T3},getClientUserAgent(X){return this.getClientUserAgentSeeded(Q.USER_AGENT,X)},getClientUserAgentSeeded(X,Y){let G={};for(let W in X){if(!Object.prototype.hasOwnProperty.call(X,W))continue;G[W]=encodeURIComponent(X[W]??"null")}let V=this._platformFunctions.getPlatformInfo();if(V&&this.getTelemetryEnabled())G.platform=encodeURIComponent(V);else delete G.platform;let U=this.getApiField("httpClient");if(U)G.httplib=encodeURIComponent(U.getClientName());if(this._appInfo)G.application=this._appInfo;Y(JSON.stringify(G))},getAppInfoAsString(){if(!this._appInfo)return"";let X=this._appInfo.name;if(this._appInfo.version)X+=`/${this._appInfo.version}`;if(this._appInfo.url)X+=` (${this._appInfo.url})`;return X},getTelemetryEnabled(){return this._enableTelemetry},_prepResources(){for(let X in t8){if(!Object.prototype.hasOwnProperty.call(t8,X))continue;this[(0,B0.pascalToCamelCase)(X)]=new t8[X](this)}},_getPropsFromConfig(X){if(!X)return{};let Y=typeof X==="string";if(!(X===Object(X)&&!Array.isArray(X))&&!Y)throw Error("Config must either be an object or a string");if(Y)return{apiVersion:X};if(Object.keys(X).filter((U)=>!D3.includes(U)).length>0)throw Error(`Config object may only contain the following: ${D3.join(", ")}`);return X},parseEventNotification(X,Y,G,V,U,W){this.webhooks.signature.verifyHeader(X,Y,G,V||this.webhooks.DEFAULT_TOLERANCE,U,W);let B=X instanceof Uint8Array?JSON.parse(new TextDecoder("utf8").decode(X)):JSON.parse(X);if(B&&B.object==="event")throw Error("You passed a webhook payload to stripe.parseEventNotification, which expects an event notification. Use stripe.webhooks.constructEvent instead.");if(B.context)B.context=B3.StripeContext.parse(B.context);return B.fetchEvent=()=>{return this._requestSender._rawRequest("GET",`/v2/core/events/${B.id}`,void 0,{stripeContext:B.context,headers:{"Stripe-Request-Trigger":`event=${B.id}`}},["fetch_event"])},B.fetchRelatedObject=()=>{if(!B.related_object)return Promise.resolve(null);return this._requestSender._rawRequest("GET",B.related_object.url,void 0,{stripeContext:B.context,headers:{"Stripe-Request-Trigger":`event=${B.id}`}},["fetch_related_object"])},B}},Q}E3.createStripe=QH});var A3=K((k3,B8)=>{Object.defineProperty(k3,"__esModule",{value:!0});var XH=fZ(),YH=C3(),GH=I8(),U9=(0,YH.createStripe)(new XH.NodePlatformFunctions);B8.exports=U9;B8.exports.Stripe=U9;B8.exports.default=U9;B8.exports.Decimal=GH.Decimal});import"@stacksjs/validation";import{log as Q$}from"@stacksjs/cli";import{db as T9}from"@stacksjs/database";async function JB($,Z={}){let{olderThanDays:J=30,column:Q="created_at",query:X}=Z;try{if(X){let W=T9.deleteFrom($);W=X(W);let B=await W.execute(),z=Array.isArray(B)?B:[B],L=Number(z[0]?.numDeletedRows??z.length??0);return Q$.info(`Pruned ${L} records from ${$}`),L}let Y=new Date;Y.setDate(Y.getDate()-J);let G=await T9.deleteFrom($).where(Q,"<",Y.toISOString()).execute(),V=Array.isArray(G)?G:[G],U=Number(V[0]?.numDeletedRows??V.length??0);return Q$.info(`Pruned ${U} records from ${$} older than ${J} days`),U}catch(Y){throw Q$.error(`Failed to prune ${$}:`,Y),Y}}async function ZT($,Z={}){return JB($,Z)}function JT($){if(!$?.prunable)return null;if(typeof $.prunable==="boolean")return{olderThanDays:30,column:"created_at"};return $.prunable}import{createCipheriv as QB,createDecipheriv as XB,createHash as YB,randomBytes as GB}from"crypto";import{log as H8}from"@stacksjs/logging";var D9="enc:",O9="aes-256-gcm",VB=12,K8=null;async function q9(){if(K8)return K8;let $=process.env.APP_KEY;if(!$)try{$=(await import("@stacksjs/config").catch(()=>null))?.config?.app?.key}catch{}if(!$)return null;return K8=YB("sha256").update($).digest(),K8}function S0($){return typeof $==="string"&&$.startsWith(D9)}async function X$($){if($==null)return $;if(S0($))return $;if(typeof $!=="string")return $;let Z=await q9();if(!Z)return H8.warn("[orm] encrypted attribute: APP_KEY not set \u2014 storing value in plaintext"),$;let J=GB(VB),Q=QB(O9,Z,J),X=Buffer.concat([Q.update($,"utf8"),Q.final()]),Y=Q.getAuthTag();return`${D9}${J.toString("base64")}:${Y.toString("base64")}:${X.toString("base64")}`}async function Y$($){if($==null)return $;if(typeof $!=="string")return $;if(!S0($))return $;try{let Z=await q9();if(!Z)return H8.warn("[orm] encrypted attribute: APP_KEY not set \u2014 cannot decrypt"),null;let[,J,Q,X]=$.split(":");if(!J||!Q||!X)return H8.warn("[orm] encrypted attribute: malformed envelope, returning null"),null;let Y=Buffer.from(J,"base64"),G=Buffer.from(Q,"base64"),V=Buffer.from(X,"base64"),U=XB(O9,Z,Y);return U.setAuthTag(G),Buffer.concat([U.update(V),U.final()]).toString("utf8")}catch(Z){return H8.warn("[orm] encrypted attribute: decrypt failed (key rotation? corrupted ciphertext?)",{error:Z}),null}}function G$($){let Z=$.attributes;if(!Z||typeof Z!=="object")return[];let J=[];for(let[Q,X]of Object.entries(Z))if(X&&typeof X==="object"&&X.encrypted===!0)J.push(Q);return J}import{log as v0}from"@stacksjs/logging";var BB=[/^password$/i,/^password_hash$/i,/^api_key$/i,/_token$/i,/_secret$/i,/^remember_token$/i],F9="model_audits",W$=null;function WB($){W$=$}async function V$(){if(W$!=null)return W$;try{let $=await import("@stacksjs/router").catch(()=>null);if(!$)return null;let Z=$.getCurrentRequest;if(typeof Z!=="function")return null;let J=Z();if(!J)return null;return(J.user??J._user)?.id??null}catch{return null}}function w8($){if(!$||typeof $!=="object")return null;let Z={};for(let[J,Q]of Object.entries($)){if(BB.some((X)=>X.test(J)))continue;Z[J]=Q}return Z}function R0($){if(!$||typeof $!=="object")return null;let Z=$;if(Z._attributes&&typeof Z._attributes==="object")return{...Z._attributes};return{...$}}function UB($,Z){if(!$||!Z)return{old:$,next:Z};let J={},Q={},X=new Set([...Object.keys($),...Object.keys(Z)]);for(let Y of X)if($[Y]!==Z[Y])J[Y]=$[Y],Q[Y]=Z[Y];return{old:J,next:Q}}async function B$($,Z=!1){try{let{db:J}=await import("@stacksjs/database");await J.insertInto(F9).values({auditable_type:$.auditable_type,auditable_id:$.auditable_id,event:$.event,old_values:$.old_values?JSON.stringify($.old_values):null,new_values:$.new_values?JSON.stringify($.new_values):null,user_id:$.user_id,created_at:new Date().toISOString()}).executeTakeFirst()}catch(J){if(v0.warn(`[orm] audit row write failed for ${$.auditable_type}#${String($.auditable_id)} (${$.event})`,{error:J}),Z)throw J}}function C9($){return{async audits(Z){try{let{db:J}=await import("@stacksjs/database");return(await J.selectFrom(F9).selectAll().where("auditable_type","=",$).where("auditable_id","=",Z).orderBy("created_at","desc").execute()??[]).map((X)=>({...X,old_values:typeof X.old_values==="string"?E9(X.old_values):X.old_values,new_values:typeof X.new_values==="string"?E9(X.new_values):X.new_values}))}catch(J){return v0.warn(`[orm] audits() lookup failed for ${$}#${String(Z)}`,{error:J}),[]}}}}function E9($){try{return JSON.parse($)}catch{return $}}function k9($){if($&&typeof $==="object"&&"transactional"in $)return{transactional:$.transactional===!0};return{transactional:!1}}function A9($,Z,J="id",Q={}){let X=Q.transactional===!0,Y=$;if(typeof $.audits!=="function")$.audits=C9(Z).audits;let G=async(B)=>{if(!X)return await B();let{db:z}=await import("@stacksjs/database");return await z.transaction(async()=>B())},V=$.create;if(typeof V==="function")$.create=async function(...B){return await G(async()=>{let z=await V.apply(this,B);try{let L=R0(z),H=L?.[J];if(H!=null){let T=await V$();await B$({auditable_type:Z,auditable_id:H,event:"created",old_values:null,new_values:w8(L),user_id:T},X)}}catch(L){if(v0.warn(`[orm] audit(create) failed for ${Z}`,{error:L}),X)throw L}return z})};let U=$.update;if(typeof U==="function")$.update=async function(B,z){return await G(async()=>{let L=Y.find,H=typeof L==="function"?R0(await L.call(Y,B)):null,T=await U.call(this,B,z);try{let D=R0(T)??(typeof L==="function"?R0(await L.call(Y,B)):null),{old:q,next:O}=UB(H,D);if(O&&Object.keys(O).length>0){let k=await V$();await B$({auditable_type:Z,auditable_id:B,event:"updated",old_values:w8(q),new_values:w8(O),user_id:k},X)}}catch(D){if(v0.warn(`[orm] audit(update) failed for ${Z}#${String(B)}`,{error:D}),X)throw D}return T})};let W=(B)=>{let z=$[B];if(typeof z!=="function")return;$[B]=async function(L){return await G(async()=>{let H=Y.find,T=typeof H==="function"?R0(await H.call(Y,L)):null,D=await z.call(this,L);try{if(D!==!1&&T){let q=await V$();await B$({auditable_type:Z,auditable_id:L,event:"deleted",old_values:w8(T),new_values:null,user_id:q},X)}}catch(q){if(v0.warn(`[orm] audit(${B}) failed for ${Z}#${String(L)}`,{error:q}),X)throw q}return D})}};W("delete"),W("softDelete")}function N9($){let Z=$;return Z?.code==="SQLITE_CONSTRAINT_UNIQUE"||Z?.code==="SQLITE_CONSTRAINT"||Z?.code==="23505"||Z?.errno===1062||/unique|duplicate/i.test(Z?.message??"")}function zB($,Z,J){let Q=$;if($ instanceof Error&&typeof Q.status==="number"&&Number.isInteger(Q.status)&&Q.status>=400&&Q.status<600){let X={error:$.message};if(Q.details!==void 0)X.details=Q.details;return{status:Q.status,body:X}}if(N9($))return{status:409,body:{error:`${Z} already exists`}};return{status:500,body:{error:`Failed to ${J} ${Z}`,detail:String($)}}}import{cacheRequestQuery as LB}from"@stacksjs/router";var T8=new WeakMap;function zT($,Z){return LB(`batchLoad:${$.name??"model"}:${String(Z)}`,async()=>{return new Promise((J,Q)=>{let X=T8.get($);if(!X)X={keys:[],resolvers:[],scheduled:!1},T8.set($,X);if(X.keys.push(Z),X.resolvers.push({key:Z,resolve:J,reject:Q}),X.scheduled)return;X.scheduled=!0,Promise.resolve().then(async()=>{let Y=T8.get($);if(!Y)return;T8.delete($);let G=Array.from(new Set(Y.keys));try{let V=typeof $.findMany==="function"?await $.findMany(G):await Promise.all(G.map((W)=>$.find?.(W))),U=new Map;for(let W of V??[]){let B=W?.id;if(B!==void 0)U.set(B,W)}for(let W of Y.resolvers)W.resolve(U.get(W.key))}catch(V){for(let U of Y.resolvers)U.reject(V)}})})})}import{db as wT}from"@stacksjs/database";class KB{conditions=[];where($,...Z){let[J,Q]=Z,X=Q===void 0?"=":J,Y=Q===void 0?J:Q;this.addCondition("and","where",$,X,Y)}orWhere($,...Z){let[J,Q]=Z,X=Q===void 0?"=":J,Y=Q===void 0?J:Q;this.addCondition("or","where",$,X,Y)}whereIn($,Z){this.conditions.push({type:"and",method:"whereIn",column:$,values:Z})}whereNotIn($,Z){this.conditions.push({type:"and",method:"whereIn",column:$,values:Z,operator:"not in"})}whereNull($){this.conditions.push({type:"and",method:"whereNull",column:$})}whereNotNull($){this.conditions.push({type:"and",method:"whereNotNull",column:$})}whereBetween($,Z){this.conditions.push({type:"and",method:"whereBetween",column:$,range:Z})}whereExists($){this.conditions.push({type:"and",method:"whereExists",column:"",callback:$})}addCondition($,Z,J,Q,X){this.conditions.push({type:$,method:Z,column:J,operator:Q,value:X})}getConditions(){return this.conditions}}import{db as D8,runInTransactionScope as HB}from"@stacksjs/database";async function OT($,Z){return await HB(async()=>{return await D8.transaction($,Z)})}function qT($){return D8.transaction(async()=>{await $()})}async function ET($){return await D8.savepoint($)}function FT($,Z){return D8.transactional($,Z)}import{path as p}from"@stacksjs/path";import{fs as a,globSync as H$}from"@stacksjs/storage";import{plural as R9,singular as x9,snakeCase as b}from"@stacksjs/strings";import{isString as O8}from"@stacksjs/validation";var U$;function v9(){if(!U$)U$=import("@stacksjs/build");return U$}async function IT($){if(typeof $==="string")$=(await import($)).default;return $.table??b(R9($?.name||""))}function y0($,Z){if($.name)return $.name;return p.basename(Z).replace(/\.ts$/,"")}function u($,Z){if($.table)return $.table;return b(R9(y0($,Z)))}function wB($,Z){let J=[$,Z];return J.sort(),J.join("_")}function PT($,Z){return Z in $}async function TB($,Z){let J=[];if($.hasOne)for(let Q of $.hasOne)J.push(await z$(Q,$,Z,"hasOne"));if($.hasMany)for(let Q of $.hasMany)J.push(await z$(Q,$,Z,"hasMany"));if($.belongsTo)for(let Q of $.belongsTo)J.push(await z$(Q,$,Z,"belongsTo"));if($.hasOneThrough)for(let Q of $.hasOneThrough)J.push(await P9(Q,$,Z,"hasOneThrough"));if($.hasManyThrough)for(let Q of $.hasManyThrough)J.push(await P9(Q,$,Z,"hasManyThrough"));if($.belongsToMany)for(let Q of $.belongsToMany)J.push(await OB(Q,$,Z,"belongsToMany"));if($.morphOne)J.push(await S9($.morphOne,$,Z,"morphOne"));if($.morphMany){let Q=Array.isArray($.morphMany)?$.morphMany:[$.morphMany];for(let X of Q)J.push(await S9(X,$,Z,"morphMany"))}if($.morphTo){let Q=$.morphTo,X=Array.isArray(Q)?Q:typeof Q==="object"&&Q!==null?[Q]:[];for(let Y of X)J.push(DB(Y,$,Z))}if($.morphToMany){let Q=Array.isArray($.morphToMany)?$.morphToMany:[$.morphToMany];for(let X of Q)J.push(I9(X,$,Z,"morphToMany"))}if($.morphedByMany){let Q=Array.isArray($.morphedByMany)?$.morphedByMany:[$.morphedByMany];for(let X of Q)J.push(I9(X,$,Z,"morphedByMany"))}return J}function DB($,Z,J){let Q=$&&typeof $==="object"&&$.name?String($.name):`${b(J)}able`,X=$?.type||`${Q}_type`;return{relationship:"morphTo",model:"",table:"",relationTable:"",foreignKey:$?.id||`${Q}_id`,modelKey:X,relationName:Q,relationModel:J,throughModel:"",throughForeignKey:"",pivotForeign:"",pivotKey:"",pivotTable:""}}function I9($,Z,J,Q){let X=typeof $==="object"&&$!==null,Y=X?String($.model||""):String($),G=X&&$.morphName?String($.morphName):`${b(J)}able`,V=X&&$.pivotTable?String($.pivotTable):G,U=X&&$.id||`${G}_id`,W=X&&$.type||`${G}_type`;return{relationship:Q,model:Y,table:"",relationTable:"",foreignKey:U,modelKey:W,relationName:G,relationModel:J,throughModel:"",throughForeignKey:"",pivotForeign:U,pivotKey:W,pivotTable:V}}async function q8($,Z){let J=K$(`${Z}.ts`),Q=K$(`${$}.ts`),X=L$(`${$}.ts`),Y=L$(`${Z}.ts`);if(!J&&!Y)throw Error(`Model not found: ${Z}`);if(!Q&&!X)throw Error(`Model not found: ${$}`);let G;try{if(a.existsSync(J))G=(await import(J)).default;else G=(await import(Y)).default}catch(U){throw Error(`Failed to load model: ${Z}. Error: ${U?.message||"Unknown error"}`)}let V=a.existsSync(Q)?Q:X;return{modelRelation:G,modelPath:V,modelRelationPath:a.existsSync(J)?J:Y}}async function P9($,Z,J,Q){let X="",Y="",G="",V="";if(O8($))X=$;else X=$.model,Y=$.relationName||"",G=$.through,V=$.throughForeignKey||"";let{modelRelation:U,modelPath:W,modelRelationPath:B}=await q8(J,X),z=u(U,B),L=u(Z,W),H=b(y0(U,B)),T=b(J);return{relationship:Q,model:X,table:z,relationTable:L,foreignKey:`${T}_id`,modelKey:`${H}_id`,relationName:Y,relationModel:J,throughModel:G,throughForeignKey:V,pivotForeign:`${T}_id`,pivotKey:`${H}_id`,pivotTable:L}}async function OB($,Z,J,Q){let X="",Y="",G="",V=b(J);if(O8($))X=$;else X=$.model,Y=$.pivotTable||"",G=$.firstForeignKey||`${V}_id`;let{modelRelation:U,modelPath:W,modelRelationPath:B}=await q8(J,X),z=u(U,B),L=u(Z,W),H=b(y0(U,B));return{relationship:Q,model:X,table:z,relationTable:L,foreignKey:typeof $==="string"?`${V}_id`:$.firstForeignKey||`${V}_id`,modelKey:typeof $==="string"?`${H}_id`:$.secondForeignKey||`${H}_id`,relationName:"",relationModel:J,throughModel:"",throughForeignKey:"",pivotForeign:G,pivotKey:`${H}_id`,pivotTable:Y}}async function S9($,Z,J,Q){let X="",Y="",G="",V="";if(O8($))X=$,Y=`${b(J)}able`;else X=$.model,Y=$.morphName||`${b(J)}able`,G=$.type||`${Y}_type`,V=$.id||`${Y}_id`;let{modelRelation:U,modelPath:W,modelRelationPath:B}=await q8(J,X),z=u(U,B),L=u(Z,W);return{relationship:Q,model:X,table:z,relationTable:L,foreignKey:V||`${Y}_id`,modelKey:G||`${Y}_type`,relationName:Y,relationModel:J,throughModel:"",throughForeignKey:"",pivotForeign:"",pivotKey:"",pivotTable:L}}async function z$($,Z,J,Q){let X="",Y="";if(O8($))X=$;else X=$.model,Y=$.relationName||"";let{modelRelation:G,modelPath:V,modelRelationPath:U}=await q8(J,X),W=u(G,U),B=u(Z,V),z=b(y0(G,U)),L=b(J),H={relationship:Q,model:X,table:W,relationTable:B,foreignKey:typeof $==="string"?`${L}_id`:$.foreignKey||`${L}_id`,modelKey:`${z}_id`,relationName:Y,relationModel:J,throughModel:"",throughForeignKey:"",pivotForeign:`${L}_id`,pivotKey:`${z}_id`,pivotTable:B};if(Q==="belongsTo")H.foreignKey="";return H}function ST($){let Z=/belongs/,J=/has/,Q=/Through/,X=/morph/;if(Q.test($))return"throughType";if(Z.test($))return"belongsType";if(J.test($))return"hasType";if(X.test($))return"morphType";return""}function RT($){let Z=/One/;if(/Many/.test($))return"many";if(Z.test($))return"one";return""}async function vT($,Z){let J=[];if("belongsToMany"in $){let Q=$.belongsToMany||[];for(let X of Q){let Y,G;if(typeof X==="string")G=X;else G=X.model;let V=K$(`${G}.ts`),U=L$(`${G}.ts`);if(a.existsSync(V))Y=(await import(V)).default;else Y=(await import(U)).default;let W=u(Y,V),B=u($,Z),z=typeof X==="object"&&"firstForeignKey"in X?X.firstForeignKey:`${x9(B)}_${$.primaryKey}`,L=typeof X==="object"&&"secondForeignKey"in X?X.secondForeignKey:`${x9(W)}_${$.primaryKey}`;J.push({table:(typeof X==="object"&&"pivotTable"in X?X.pivotTable:void 0)??wB(B,W),firstForeignKey:z,secondForeignKey:L})}return J}return[]}async function yT($){let Z=H$([p.userModelsPath("*.ts"),p.storagePath("framework/defaults/app/Models/**/*.ts")],{absolute:!0}),J=[];for(let Q=0;Q<Z.length;Q++){let X=Z[Q],Y=await import(X);if($===Y.default.name)continue;let G=y0(Y,X),V=await TB(Y.default,G);if(!V.length)continue;let U=V.find((W)=>W.model===$);if(U)J.push(U)}return J}function bT($){if($===void 0)return[];return Object.keys($).filter((Z)=>{return $[Z]?.hidden===!0})}function jT($){let Z=$.attributes;if(Z===void 0)return[];return Object.keys(Z).filter((J)=>{return Z[J]?.guarded===!0}).map((J)=>b(J))}function fT($,Z){let J=$.attributes,Q=[];if(J===void 0)return[];let X=typeof $.traits?.billable==="object"||typeof $.traits?.billable==="boolean",Y=typeof $.traits?.useAuth==="object"?$.traits?.useAuth.usePasskey:!1,G=$.traits?.useUuid||!1;if(X)Q.push("stripe_id");if(G)Q.push("uuid");if(Y)Q.push(...["two_factor_secret","public_key"]);let V=Z.map((U)=>U.foreignKey).filter((U)=>U);return[...Object.keys(J).filter((U)=>{if(J===void 0)return!1;return J[U]?.fillable===!0}).map((U)=>b(U)),...Q,...V]}async function MT($,Z){let J=$.attributes;if(!J)J={};let Q=Object.keys(J),X=[],Y=Bun.file(Z),G="";try{if(await Y.exists())G=await Y.text()}catch{G=""}let V=/rule:.*$/gm,U;U=V.exec(G);while(U!==null)X.push(U[0]),U=V.exec(G);return Q.map((B,z)=>{let L=J[B],H=null,T=!1,D=!1,q=!1,O=!1;if(L)H=L||null,T=L.unique||!1,D=L.hidden||!1,q=L.fillable||!1;let k=X[z]??"";return O=(L.validation?.rule).isRequired??!1,{field:B,default:H,unique:T,hidden:D,fillable:q,required:O,fieldArray:qB(k)}})}function qB($){let Z=$.split("rule: schema.");if(Z.length!==2)return null;if(!Z[1])Z[1]="";let J=Z[1].replace(/,/g,"");if(!J)return null;let Q=J.split("."),X=/\(([^)]+)\)/;return Q.map((Y)=>{let G=X.exec(Y),V=G?G[1]:null;return{entity:Y.replace(X,"").replace(/\(|\)/g,""),charValue:V}})[0]||null}function _T($){let Z=$.fieldArray?.entity;switch(Z){case"enum":return"string | string[]";case"date":return"Date | string";case"timestamp":return"Date | string";case"datetime":return"Date | string";case"float":return"number";case"double":return"number";case"decimal":return"number";case"integer":return"number";case"bigint":return"number";default:return Z}}async function gT($){let{generator:Z,parser:J,traverse:Q}=await v9(),X=a.readFileSync($,"utf8"),Y=J.parse(X,{sourceType:"module",plugins:["typescript","classProperties","decorators-legacy"]}),G=[];return Q(Y,{ImportDeclaration(V){let U=Z(V.node,{},X);G.push(U.code)}}),G}async function hT($){let{generator:Z,parser:J,traverse:Q}=await v9(),X=a.readFileSync($,"utf8"),Y=J.parse(X,{sourceType:"module",plugins:["typescript","classProperties","decorators-legacy"]}),G;return Q(Y,{ObjectExpression(V){let U=V.node.properties.find((W)=>W.type==="ObjectProperty"&&W.key.type==="Identifier"&&W.key.name==="attributes");if(U&&U.type==="ObjectProperty"&&U.value)G=Z(U.value,{},X).code,V.stop()}}),G}function L$($){let Z=p.join(p.storagePath("framework/defaults/app/Models"),"/"),J=p.join(Z,$);if(a.existsSync(J))return J;return H$(`${Z}**/${$}`,{absolute:!0})[0]??""}function K$($){let Z=p.join(p.userModelsPath("/"),"/"),J=p.join(Z,$);if(a.existsSync(J))return J;return H$(`${Z}**/${$}`,{absolute:!0})[0]??""}function mT($){let Z=typeof $==="number"?new Date($):typeof $==="string"?new Date($):$;if(Number.isNaN(Z.getTime()))throw Error(`Invalid date value: ${String($)}`);return Z.toISOString().replace("T"," ").split(".")[0]??""}function uT($){return $.toISOString().split("T")[0]??""}function cT($){return $.getTime()}import{createModel as zH,registerModel as LH}from"@stacksjs/query-builder";import{log as h}from"@stacksjs/logging";import{snakeCase as Z$}from"@stacksjs/strings";import{AsyncLocalStorage as KH}from"async_hooks";function EB($){if($===null||typeof $!=="object")return!1;let Z=$;return Array.isArray(Z.data)&&typeof Z.current_page==="number"&&typeof Z.per_page==="number"&&typeof Z.total==="number"&&typeof Z.last_page==="number"}function FB($){if($===null||typeof $!=="object")return!1;let Z=$;return Array.isArray(Z.data)&&typeof Z.current_page==="number"&&typeof Z.per_page==="number"&&typeof Z.has_more_pages==="boolean"&&!("total"in Z)}function CB($){if($===null||typeof $!=="object")return!1;let Z=$;return Array.isArray(Z.data)&&(typeof Z.next_cursor==="string"||Z.next_cursor===null)}function w$($){let{data:Z}=$,{perPage:J,page:Q,total:X,lastPage:Y}=$.meta,G=Z.length===0,V=G?null:(Q-1)*J+1,U=G?null:V+Z.length-1;return{data:Z,current_page:Q,per_page:J,total:X,last_page:Y,from:V,to:U,has_more_pages:Q<Y}}function T$($){return{data:$.data,current_page:$.meta.page,per_page:$.meta.perPage,has_more_pages:$.meta.hasMore}}function D$($){return{data:$.data,per_page:$.meta.perPage,next_cursor:y9($.meta.nextCursor),prev_cursor:y9($.meta.prevCursor),has_more_pages:$.meta.nextCursor!==null&&$.meta.nextCursor!==void 0}}function y9($){if($===null||$===void 0)return null;if(typeof $==="string")return $;return JSON.stringify($)}function q$($,Z){let J=C$(),Q=J?O$(J,"per_page"):void 0,X=J?O$(J,"page"):void 0,Y=$!==void 0?Math.max(1,Math.floor($)):Math.min(100,Math.max(1,Q??15)),G=Math.max(1,Math.floor(Z??X??1));return{perPage:Y,page:G}}function E$($,Z){let J=C$(),Q=J?j9(J,"cursor"):void 0,X=J?O$(J,"per_page"):void 0,Y=$!==void 0?Math.max(1,Math.floor($)):Math.min(100,Math.max(1,X??15)),V=b9(Z!==void 0?Z:Q??null);return{perPage:Y,cursor:V}}function b9($){if($===null||$===void 0)return null;if(Array.isArray($))return $;if(typeof $==="string"&&$.startsWith("["))try{let Z=JSON.parse($);if(Array.isArray(Z))return Z}catch{}return $}function F$($){let Z=C$();if(!Z)return $;let J=(()=>{try{return new URL(Z.url)}catch{return null}})();if(!J)return $;let Q=J.pathname;if($.path=Q,"next_cursor"in $)return $.next_page_url=$.next_cursor!==null?Z0(J,{cursor:$.next_cursor}):null,$.prev_page_url=$.prev_cursor!==null?Z0(J,{cursor:$.prev_cursor}):null,$;let X=$.current_page;if($.prev_page_url=X>1?Z0(J,{page:X-1}):null,"total"in $){let Y=$.last_page;$.next_page_url=X<Y?Z0(J,{page:X+1}):null,$.first_page_url=Z0(J,{page:1}),$.last_page_url=Z0(J,{page:Y})}else $.next_page_url=$.has_more_pages?Z0(J,{page:X+1}):null;return $}function Z0($,Z){let J=new URL($.toString());for(let[Q,X]of Object.entries(Z))J.searchParams.set(Q,String(X));return`${J.pathname}${J.search}`}var K0;function C$(){if(K0===null)return;if(K0===void 0)try{let Z=C("@stacksjs/router");if(typeof Z.getCurrentRequest==="function")K0=Z.getCurrentRequest;else{K0=null;return}}catch{K0=null;return}return K0()}function O$($,Z){let J=j9($,Z);if(J===void 0)return;let Q=Number(J);return Number.isFinite(Q)?Q:void 0}function j9($,Z){let J=$.query?.[Z];if(J===void 0)return;return Array.isArray(J)?J[0]:J}import{db as kB,sql as AB}from"@stacksjs/database";function k$($,Z){if(typeof $!=="number"||!Number.isFinite($)||$<=0)throw Error(`[orm/taggable] ${Z} requires a positive numeric id (received ${String($)})`)}function f9($){let Z=kB;return{async tags(J){return k$(J,"tags"),await Z.selectFrom("taggable").where("taggable_id","=",J).where("taggable_type","=",$).selectAll().execute()},async tagCount(J){k$(J,"tagCount");let Q=await Z.selectFrom("taggable").select(AB`count(*) as count`).where("taggable_id","=",J).where("taggable_type","=",$).executeTakeFirst();return Number(Q?.count)||0},async addTag(J,Q){if(k$(J,"addTag"),!Q||typeof Q.name!=="string"||Q.name.trim().length===0)throw Error("[orm/taggable] addTag requires a non-empty tag.name");return await Z.insertInto("taggable").values({...Q,taggable_id:J,taggable_type:$,slug:Q.name.toLowerCase().replace(/[^a-z0-9]+/g,"-"),order:0,is_active:!0,created_at:new Date().toISOString(),updated_at:new Date().toISOString()}).returningAll().executeTakeFirst()},async activeTags(J){return await Z.selectFrom("taggable").where("taggable_id","=",J).where("taggable_type","=",$).where("is_active","=",!0).selectAll().execute()},async inactiveTags(J){return await Z.selectFrom("taggable").where("taggable_id","=",J).where("taggable_type","=",$).where("is_active","=",!1).selectAll().execute()},async removeTag(J,Q){await Z.deleteFrom("taggable").where("taggable_id","=",J).where("taggable_type","=",$).where("id","=",Q).execute()}}}import{db as NB}from"@stacksjs/database";function M9($){let Z=NB;async function J(Q){return(await Z.selectFrom("categorizable_models").where("categorizable_id","=",Q).where("categorizable_type","=",$).selectAll().execute()).map((Y)=>Y.category_id)}return{async categories(Q){let X=await J(Q);if(X.length===0)return[];return await Z.selectFrom("categorizable").where("id","in",X).selectAll().execute()},async categoryCount(Q){return(await J(Q)).length},async addCategory(Q,X){let Y=await Z.selectFrom("categorizable").where("name","=",X.name).selectAll().executeTakeFirst();if(!Y)Y=await Z.insertInto("categorizable").values({name:X.name,description:X.description,slug:X.name.toLowerCase().replace(/[^a-z0-9]+/g,"-"),is_active:!0,created_at:new Date().toISOString(),updated_at:new Date().toISOString()}).returningAll().executeTakeFirst();return await Z.insertInto("categorizable_models").values({categorizable_id:Q,categorizable_type:$,category_id:Y.id,created_at:new Date().toISOString(),updated_at:new Date().toISOString()}).returningAll().executeTakeFirst()},async activeCategories(Q){let X=await J(Q);if(X.length===0)return[];return await Z.selectFrom("categorizable").where("id","in",X).where("is_active","=",!0).selectAll().execute()},async inactiveCategories(Q){let X=await J(Q);if(X.length===0)return[];return await Z.selectFrom("categorizable").where("id","in",X).where("is_active","=",!1).selectAll().execute()},async removeCategory(Q,X){await Z.deleteFrom("categorizable_models").where("categorizable_id","=",Q).where("categorizable_type","=",$).where("category_id","=",X).execute()}}}import{db as xB,sql as IB}from"@stacksjs/database";function _9($,Z){if(typeof $!=="number"||!Number.isFinite($)||$<=0)throw Error(`[orm/commentable] ${Z} requires a positive numeric id (received ${String($)})`)}function g9($){let Z=xB;return{async comments(J){return _9(J,"comments"),await Z.selectFrom("comments").where("commentables_id","=",J).where("commentables_type","=",$).selectAll().execute()},async commentCount(J){let Q=await Z.selectFrom("comments").select(IB`count(*) as count`).where("commentables_id","=",J).where("commentables_type","=",$).executeTakeFirst();return Number(Q?.count)||0},async addComment(J,Q){if(_9(J,"addComment"),!Q||typeof Q.title!=="string"||Q.title.trim().length===0)throw Error("[orm/commentable] addComment requires a non-empty comment.title");if(typeof Q.body!=="string"||Q.body.trim().length===0)throw Error("[orm/commentable] addComment requires a non-empty comment.body");return await Z.insertInto("comments").values({...Q,commentables_id:J,commentables_type:$,status:"pending",created_at:new Date().toISOString(),updated_at:new Date().toISOString()}).returningAll().executeTakeFirst()},async approvedComments(J){return await Z.selectFrom("comments").where("commentables_id","=",J).where("commentables_type","=",$).where("status","=","approved").selectAll().execute()},async pendingComments(J){return await Z.selectFrom("comments").where("commentables_id","=",J).where("commentables_type","=",$).where("status","=","pending").selectAll().execute()},async rejectedComments(J){return await Z.selectFrom("comments").where("commentables_id","=",J).where("commentables_type","=",$).where("status","=","rejected").selectAll().execute()}}}import{db as VH}from"@stacksjs/database";function N3($){let Z=VH;return{async createStripeUser(J,Q){let{manageCustomer:X}=await import("@stacksjs/payments");return await X.createStripeCustomer(J,Q)},async updateStripeUser(J,Q){let{manageCustomer:X}=await import("@stacksjs/payments");return await X.updateStripeCustomer(J,Q)},async deleteStripeUser(J){let{manageCustomer:Q}=await import("@stacksjs/payments");return await Q.deleteStripeUser(J)},async createOrGetStripeUser(J,Q){let{manageCustomer:X}=await import("@stacksjs/payments");return await X.createOrGetStripeUser(J,Q)},async retrieveStripeUser(J){let{manageCustomer:Q}=await import("@stacksjs/payments");return await Q.retrieveStripeUser(J)},async defaultPaymentMethod(J){let{managePaymentMethod:Q}=await import("@stacksjs/payments");return await Q.retrieveDefaultPaymentMethod(J)},async setDefaultPaymentMethod(J,Q){let{managePaymentMethod:X}=await import("@stacksjs/payments");return await X.setDefaultPaymentMethod(J,Q)},async addPaymentMethod(J,Q){let{managePaymentMethod:X}=await import("@stacksjs/payments");return await X.addPaymentMethod(J,Q)},async paymentMethods(J,Q){let{managePaymentMethod:X}=await import("@stacksjs/payments");return await X.listPaymentMethods(J,Q)},async newSubscription(J,Q,X,Y={}){let{manageSubscription:G}=await import("@stacksjs/payments"),V=await G.create(J,Q,X,Y),W=V.latest_invoice?.payment_intent;return{subscription:V,paymentIntent:W}},async updateSubscription(J,Q,X,Y={}){let{manageSubscription:G}=await import("@stacksjs/payments"),V=await G.update(J,Q,X,Y),W=V.latest_invoice?.payment_intent;return{subscription:V,paymentIntent:W}},async cancelSubscription(J,Q,X={}){let{manageSubscription:Y}=await import("@stacksjs/payments");return{subscription:await Y.cancel(Q,X)}},async activeSubscription(J){let{manageSubscription:Q}=await import("@stacksjs/payments"),X=await Z.selectFrom("subscriptions").where("user_id","=",J.id).where("provider_status","=","active").selectAll().executeTakeFirst();if(X){let Y=await Q.retrieve(J,X.provider_id||"");return{subscription:X,providerSubscription:Y}}return},async checkout(J,Q,X={}){let{manageCheckout:Y,manageCustomer:G}=await import("@stacksjs/payments"),V={};if(X.enableTax)V.automatic_tax={enabled:!0},delete X.enableTax;if(X.allowPromotions)V.allow_promotion_codes=!0,delete X.allowPromotions;let B={...{mode:"payment",customer:(await G.createOrGetStripeUser(J,{})).id,line_items:Q.map((z)=>({price:z.priceId,quantity:z.quantity||1}))},...V,...X};return await Y.create(J,B)},async createSetupIntent(J,Q={}){let{manageSetupIntent:X}=await import("@stacksjs/payments");return await X.create(J,Q)},async subscriptionHistory(J){let{manageInvoice:Q}=await import("@stacksjs/payments");return await Q.list(J)},async transactionHistory(J){let{manageTransaction:Q}=await import("@stacksjs/payments");return await Q.list(J)},async connectAccount(J,Q={}){let X=Q.accountColumn||"stripe_account_id",Y=(J._attributes??J)[X];if(!Y)return null;let G=await W8();try{return await G.accounts.retrieve(Y)}catch{return null}},async createConnectAccount(J,Q={}){let X=Q.accountColumn||"stripe_account_id",Y=J._attributes??J,G=Y[X],V=await W8();if(!G){let{stacksIdempotencyKey:U}=await import("@stacksjs/payments"),W=Q.modelTable||$,B=await V.accounts.create({type:Q.type??"express",email:Q.email??Y.email,country:Q.country??"US",capabilities:Q.capabilities??{card_payments:{requested:!0},transfers:{requested:!0}}},{idempotencyKey:U("connect.account.create",W,Y.id)});return G=B.id,await Z.updateTable(W).set({[X]:G}).where("id","=",Number(Y.id)).execute(),B}return await V.accounts.retrieve(G)},async connectOnboardLink(J,Q){let X=Q.accountColumn||"stripe_account_id",G=(J._attributes??J)[X];if(!G)throw Error("connectOnboardLink: model has no Stripe Connect account; call createConnectAccount first");return{url:(await(await W8()).accountLinks.create({account:G,refresh_url:Q.refreshUrl,return_url:Q.returnUrl,type:Q.type??"account_onboarding"})).url,accountId:G}},async syncConnectStatus(J,Q={}){let X=Q.accountColumn||"stripe_account_id",Y=Q.chargesColumn||"charges_enabled",G=Q.payoutsColumn||"payouts_enabled",V=J._attributes??J,U=V[X];if(!U)return{chargesEnabled:!1,payoutsEnabled:!1};let B=await(await W8()).accounts.retrieve(U),z=!!B.charges_enabled,L=!!B.payouts_enabled,H=Q.modelTable||$;return await Z.updateTable(H).set({[Y]:z,[G]:L}).where("id","=",Number(V.id)).execute(),{chargesEnabled:z,payoutsEnabled:L}},async chargeWithSplit(J,Q){let X=await W8(),Y=Q.accountColumn||"stripe_account_id",G=J._attributes??J,V=Q.connectAccountId||G[Y],U={amount:Q.amountCents,currency:Q.currency||"usd",automatic_payment_methods:{enabled:!0},metadata:Q.metadata};if(V){if(U.transfer_data={destination:V},Q.platformFeeCents)U.application_fee_amount=Q.platformFeeCents}let{freshIdempotencyKey:W}=await import("@stacksjs/payments");return await X.paymentIntents.create(U,{idempotencyKey:W("payment_intent.create",G.id,Q.amountCents)})}}}async function W8(){let $=globalThis.process?.env?.STRIPE_SECRET_KEY;if(!$)throw Error("Stripe Connect: STRIPE_SECRET_KEY not configured");return new(await Promise.resolve().then(() => ZB(A3(),1))).default($,{apiVersion:"2024-06-20"})}import{db as BH}from"@stacksjs/database";function x3($,Z){let J=BH,Q=Z?.table||`${$}_likes`,X=Z?.foreignKey||`${$.replace(/s$/,"")}_id`;return{async likes(Y){return await J.selectFrom(Q).where(X,"=",Y).selectAll().execute()},async likeCount(Y){let G=await J.selectFrom(Q).select("count(*) as count").where(X,"=",Y).executeTakeFirst();return Number(G?.count)||0},async like(Y,G){if(typeof Y!=="number"||!Number.isFinite(Y)||Y<=0)throw Error(`[orm/likeable] like requires a positive numeric id (received ${String(Y)})`);if(typeof G!=="number"||!Number.isFinite(G)||G<=0)throw Error(`[orm/likeable] like requires a positive numeric userId (received ${String(G)})`);let V=new Date().toISOString();try{return await J.insertInto(Q).values({[X]:Y,user_id:G,created_at:V,updated_at:V}).returningAll().executeTakeFirst()}catch(U){let W=U;if(!(W.code==="SQLITE_CONSTRAINT_UNIQUE"||W.code==="SQLITE_CONSTRAINT"||W.code==="23505"||W.errno===1062||/unique|duplicate/i.test(W.message??"")))throw U;let z=await J.selectFrom(Q).where(X,"=",Y).where("user_id","=",G).selectAll().executeTakeFirst();if(z)return z;throw U}},async unlike(Y,G){await J.deleteFrom(Q).where(X,"=",Y).where("user_id","=",G).execute()},async isLiked(Y,G){return!!await J.selectFrom(Q).where(X,"=",Y).where("user_id","=",G).selectAll().executeTakeFirst()},async likedBy(Y){return(await J.selectFrom(Q).select([X]).where("user_id","=",Y).execute()).map((V)=>Number(V[X])).filter(Boolean)}}}function I3(){return{async generateTwoFactorForModel($){let{generateTwoFactorSecret:Z}=await import("@stacksjs/auth"),J=Z();await $.update({two_factor_secret:J})},async verifyTwoFactorCode($,Z){let J=$.get("two_factor_secret");if(typeof J!=="string")return!1;let{verifyTwoFactorCode:Q,RateLimiter:X}=await import("@stacksjs/auth"),Y=String($.id??$.get?.("id")??$.get?.("email")??J),G=`2fa:${Y}`;if(await X.isRateLimited(G)){let{HttpError:U}=await import("@stacksjs/error-handling");throw new U(429,"Too many verification attempts. Please try again later.")}if(!await Q(Z,J))return await X.recordFailedAttempt(G),!1;try{let{cache:U}=await import("@stacksjs/cache"),W=`2fa:used:${Y}:${Z}`;if(await U.has(W))return await X.recordFailedAttempt(G),!1;await U.set(W,"1",90)}catch{}return await X.resetAttempts(G),!0}}}import{log as x0}from"@stacksjs/logging";var e8="deleted_at";function P3($,Z="id"){return{async softDelete(J){let Q=new Date().toISOString(),X=$.where(Z,J);if(typeof X?.update==="function")return await X.update({[e8]:Q}),!0;return!1},async restore(J){let Q=$.where(Z,J);if(typeof Q?.update==="function")return await Q.update({[e8]:null}),!0;return!1},async forceDelete(J){let Q=$.where(Z,J);if(typeof Q?.delete==="function")return await Q.delete(),!0;return!1},withTrashed(){return typeof $.query==="function"?$.query():$},onlyTrashed(){let J=typeof $.query==="function"?$.query():$;if(typeof J?.whereNotNull==="function")return J.whereNotNull(e8);return J?.where?.(e8,"!=",null)??J}}}function S3($){if($===!0||$==null)return{};if(typeof $==="object"&&!Array.isArray($)){let Z=$;if(Array.isArray(Z.cascade)){let J=Z.cascade.filter((Q)=>typeof Q==="string");return J.length?{cascade:J}:{}}return{}}return{}}function WH($,Z){let J=$.hasMany??[],Q=$.hasOne??[],X=J.some((B)=>z9(B,Z,!0)),Y=Q.some((B)=>z9(B,Z,!1));if(!X&&!Y)return x0.warn(`[orm] soft-delete cascade: '${Z}' is not a declared hasMany/hasOne relation \u2014 skipping`),null;let V=(X?J:Q).find((B)=>z9(B,Z,X))??null;if(!V)return null;let W=globalThis[V];if(!W)return x0.warn(`[orm] soft-delete cascade: model '${V}' is not yet on globalThis \u2014 skipping cascade for '${Z}'`),null;return{className:V,model:W}}function z9($,Z,J){let Q=$.toLowerCase();if(Z===Q)return!0;if(J&&Z===`${Q}s`)return!0;if(J&&Q.endsWith("y")&&Z===`${Q.slice(0,-1)}ies`)return!0;return!1}async function UH($,Z,J,Q,X){try{let Y=J.where;if(typeof Y!=="function"){x0.warn(`[orm] cascade ${X}: child model has no .where()`);return}if(X==="softDelete"){let G=J.softDelete;if(typeof G==="function"){let U=Y.call(J,Q,Z),W=typeof U?.get==="function"?await U.get():Array.isArray(U)?U:[],B=J.primaryKey||"id";for(let z of W){let L=z?.[B];if(L!=null)await G.call(J,L)}return}let V=Y.call(J,Q,Z);if(typeof V?.delete==="function"){x0.debug(`[orm] cascade soft-delete: child has no softDeletes trait, hard-deleting from ${String(J.table??"?")}`),await V.delete();return}}else{let G=J.restore;if(typeof G!=="function"){x0.debug("[orm] cascade restore: child has no restore() \u2014 nothing to do");return}let V=J.withTrashed,W=(typeof V==="function"?V.call(J):J).where?.(Q,Z),B=typeof W?.get==="function"?await W.get():[],z=J.primaryKey||"id";for(let L of B){let H=L?.[z];if(H!=null)await G.call(J,H)}}}catch(Y){if(x0.warn(`[orm] soft-delete cascade ${X} on ${$}#${String(Z)} failed`,{error:Y}),process.env.STACKS_ORM_CASCADE_SWALLOW!=="true")throw Y}}async function U8($,Z,J,Q){let X=Z.cascade;if(!X||X.length===0)return;let Y=`${$.name.toLowerCase()}_id`;for(let G of X){let V=WH($,G);if(!V)continue;await UH(V.className,J,V.model,Y,Q)}}var _3=new KH;function U0(){return _3.getStore()?.suppressed===!0}function W0($){return Promise.resolve(_3.run({suppressed:!0},$))}var R3=new Set;function HH($,Z){let J=typeof $==="string"?$.slice(0,80):String($),Q=`${typeof $}:${J}`;if(R3.has(Q))return;R3.add(Q);let X=Z instanceof Error?Z.message:String(Z);console.error(`[orm] JSON cast failed to parse value (returning null): ${X} \u2014 value preview: ${JSON.stringify(J)}`)}var wH={string:{get:($)=>$!=null?String($):null,set:($)=>$!=null?String($):null},number:{get:($)=>$!=null?Number($):null,set:($)=>$!=null?Number($):null},integer:{get:($)=>$!=null?Math.trunc(Number($)):null,set:($)=>$!=null?Math.trunc(Number($)):null},float:{get:($)=>$!=null?Number.parseFloat(String($)):null,set:($)=>$!=null?Number.parseFloat(String($)):null},boolean:{get:($)=>$===1||$==="1"||$===!0||$==="true",set:($)=>$===!0||$===1||$==="1"||$==="true"?1:0},json:{get:($)=>{if($==null)return null;if(typeof $==="string")try{return JSON.parse($)}catch(Z){return HH($,Z),null}return $},set:($)=>{if($==null)return null;return typeof $==="string"?$:JSON.stringify($)}},datetime:{get:($)=>$?new Date($):null,set:($)=>$ instanceof Date?$.toISOString():$},date:{get:($)=>$?new Date($):null,set:($)=>$ instanceof Date?$.toISOString().split("T")[0]:$},array:{get:($)=>{if($==null)return[];if(Array.isArray($))return $;if(typeof $==="string")try{return JSON.parse($)}catch{return[]}return[]},set:($)=>{if($==null)return null;return Array.isArray($)?JSON.stringify($):$}}};function g3($){return typeof $==="string"?wH[$]:$}function v3($,Z,J){if(!$||typeof $!=="object")return $;let Q={...$};for(let[X,Y]of Object.entries(Z))if(X in Q){let G=g3(Y);Q[X]=G[J](Q[X])}return Q}var $$=new Set(["_attributes","_original","_definition","_hasSaved","_relations"]),y3=Symbol.for("stacks.modelInstanceProxy"),TH={tags:{bag:"_taggable",mode:"id"},tagCount:{bag:"_taggable",mode:"id"},addTag:{bag:"_taggable",mode:"id"},activeTags:{bag:"_taggable",mode:"id"},inactiveTags:{bag:"_taggable",mode:"id"},removeTag:{bag:"_taggable",mode:"id"},categories:{bag:"_categorizable",mode:"id"},categoryCount:{bag:"_categorizable",mode:"id"},addCategory:{bag:"_categorizable",mode:"id"},activeCategories:{bag:"_categorizable",mode:"id"},inactiveCategories:{bag:"_categorizable",mode:"id"},removeCategory:{bag:"_categorizable",mode:"id"},comments:{bag:"_commentable",mode:"id"},commentCount:{bag:"_commentable",mode:"id"},addComment:{bag:"_commentable",mode:"id"},approvedComments:{bag:"_commentable",mode:"id"},pendingComments:{bag:"_commentable",mode:"id"},rejectedComments:{bag:"_commentable",mode:"id"},likes:{bag:"_likeable",mode:"id"},likeCount:{bag:"_likeable",mode:"id"},like:{bag:"_likeable",mode:"id"},unlike:{bag:"_likeable",mode:"id"},isLiked:{bag:"_likeable",mode:"id"},createStripeUser:{bag:"_billable",mode:"model"},updateStripeUser:{bag:"_billable",mode:"model"},deleteStripeUser:{bag:"_billable",mode:"model"},createOrGetStripeUser:{bag:"_billable",mode:"model"},retrieveStripeUser:{bag:"_billable",mode:"model"},defaultPaymentMethod:{bag:"_billable",mode:"model"},setDefaultPaymentMethod:{bag:"_billable",mode:"model"},addPaymentMethod:{bag:"_billable",mode:"model"},paymentMethods:{bag:"_billable",mode:"model"},newSubscription:{bag:"_billable",mode:"model"},updateSubscription:{bag:"_billable",mode:"model"},cancelSubscription:{bag:"_billable",mode:"model"},activeSubscription:{bag:"_billable",mode:"model"},checkout:{bag:"_billable",mode:"model"},createSetupIntent:{bag:"_billable",mode:"model"},subscriptionHistory:{bag:"_billable",mode:"model"},transactionHistory:{bag:"_billable",mode:"model"},connectAccount:{bag:"_billable",mode:"model"},createConnectAccount:{bag:"_billable",mode:"model"},connectOnboardLink:{bag:"_billable",mode:"model"},syncConnectStatus:{bag:"_billable",mode:"model"},chargeWithSplit:{bag:"_billable",mode:"model"},generateTwoFactorForModel:{bag:"_twoFactor",mode:"model"},verifyTwoFactorCode:{bag:"_twoFactor",mode:"model"}};function DH($,Z){if(!$||!Z)return null;let J=Z.split("."),Q=$;for(let X of J){if(Q==null||typeof Q!=="object")return null;let Y=Q;if("_attributes"in Y&&Y._attributes&&typeof Y._attributes==="object"){let G=Y._attributes;if(X in G){Q=G[X];continue}}if(X in Y){Q=Y[X];continue}return null}return Q??null}function m($,Z){if(!$||typeof $!=="object")return $;if($[y3])return $;let J=$._attributes;if(!J||typeof J!=="object")return $;if(Z&&Object.keys(Z).length>0){for(let[Q,X]of Object.entries(Z))if(Object.prototype.hasOwnProperty.call(J,Q))J[Q]=g3(X).get(J[Q])}return new Proxy($,{get(Q,X,Y){if(X===y3)return!0;if(X==="saveAsync")return async function(){let V=Q._definition,U=V?.set;if(U&&typeof Q.isDirty==="function"){for(let[B,z]of Object.entries(U)){if(typeof z!=="function")continue;if(!Q.isDirty(B))continue;let L=z(Q._attributes),H=L&&typeof L.then==="function"?await L:L;Q._attributes[B]=H}let W=V.set;V.set={};try{return Q.save()}finally{V.set=W}}return Q.save()};if(X==="save")return function(){let V=Q._definition,U=V?.set;if(U&&Object.keys(U).length>0&&typeof Q.isDirty==="function"){for(let[B,z]of Object.entries(U)){if(typeof z!=="function")continue;if(!Q.isDirty(B))continue;let L=z(Q._attributes);if(L&&typeof L.then==="function")throw Error(`Setter for "${B}" returned a Promise \u2014 use \`saveAsync()\` instead of \`save()\` when a model has async setters.`);Q._attributes[B]=L}let W=V.set;V.set={};try{return Q.save()}finally{V.set=W}}return Q.save()};if(X==="updateAsync")return async function(V){if(V&&typeof V==="object"&&!Array.isArray(V))for(let[U,W]of Object.entries(V))Y[U]=W;return Y.saveAsync()};if(X==="saveQuietly")return function(){return W0(()=>Q.save())};if(X==="saveAsyncQuietly")return function(){return W0(()=>Y.saveAsync())};if(X==="updateQuietly")return function(V){return W0(()=>Q.update(V))};if(X==="updateAsyncQuietly")return function(V){return W0(()=>Y.updateAsync(V))};if(X==="deleteQuietly")return function(){return W0(()=>Q.delete())};if(X==="toSearchableObject")return function(){let W=Q._definition?.traits?.useSearch;if(!W)return null;let B=Q._attributes;if(!B)return null;if(W===!0){let D={...B};if(B.id!=null)D.id=String(B.id);return D}let z={},L=W.displayable?.length?W.displayable:[...W.searchable??[],...W.filterable??[],...W.sortable??[],"id"],H=W.denormalize??{},T=Q._relations;for(let D of L){let q=Z$(D),O=B[q]??B[D];if(O!==void 0){z[q]=O;continue}let k=H[D]??H[q];if(k){z[q]=DH(T,k);continue}z[q]=void 0}if(B.id!=null)z.id=String(B.id);return z};if(typeof X==="string"&&!$$.has(X)){let V=Q._attributes;if(V&&Object.prototype.hasOwnProperty.call(V,X))return V[X];let U=Q._relations;if(U&&Object.prototype.hasOwnProperty.call(U,X)){let B=U[X];if(Array.isArray(B))return B.map((z)=>m(z,Z));return m(B,Z)}let W=TH[X];if(W){let L=Q._definition?.__traitMethods?.[W.bag]?.[X];if(typeof L==="function")return W.mode==="model"?(...H)=>L(Y,...H):(...H)=>L(Q.id,...H)}}let G=Reflect.get(Q,X,Q);return typeof G==="function"?G.bind(Q):G},set(Q,X,Y,G){if(typeof X==="string"&&!$$.has(X)){let{_attributes:V,set:U}=Q;if(V&&Object.prototype.hasOwnProperty.call(V,X)){if(typeof U==="function")U.call(Q,X,Y);else V[X]=Y;return!0}if(V&&!(X in Q)){if(typeof U==="function")U.call(Q,X,Y);else V[X]=Y;return!0}}return Reflect.set(Q,X,Y,G)},has(Q,X){if(typeof X==="string"&&!$$.has(X)){let Y=Q._attributes;if(Y&&Object.prototype.hasOwnProperty.call(Y,X))return!0;let G=Q._relations;if(G&&Object.prototype.hasOwnProperty.call(G,X))return!0}return Reflect.has(Q,X)},deleteProperty(Q,X){if(typeof X==="string"&&!$$.has(X)){let Y=Q._attributes;if(Y&&Object.prototype.hasOwnProperty.call(Y,X))return delete Y[X],!0}return Reflect.deleteProperty(Q,X)},ownKeys(Q){let X=Q._attributes;return X?Object.keys(X):[]},getOwnPropertyDescriptor(Q,X){if(typeof X==="string"){let Y=Q._attributes;if(Y&&Object.prototype.hasOwnProperty.call(Y,X))return{configurable:!0,enumerable:!0,value:Y[X],writable:!0}}return Object.getOwnPropertyDescriptor(Q,X)}})}var OH=new Set(["get","first","last","firstOrFail","find","findOrFail","all","paginate","simplePaginate","cursorPaginate"]),qH={paginate:w$,simplePaginate:T$,cursorPaginate:D$},b3=Symbol.for("stacks.queryBuilderProxy");function h3($,Z){if(!$||typeof $!=="object")return $;if($[b3])return $;return new Proxy($,{get(J,Q,X){if(Q===b3)return!0;let Y=Reflect.get(J,Q,X);if(typeof Y!=="function")return Y;return function(...G){let V=G,U=String(Q);if(U==="paginate"||U==="simplePaginate"){let{perPage:z,page:L}=q$(G[0],G[1]);V=[z,L]}else if(U==="cursorPaginate"){let{perPage:z,cursor:L}=E$(G[0],G[1]);V=[z,L,G[2],G[3]]}let W=Y.apply(J,V),B=(z)=>{if(OH.has(U)){if(Array.isArray(z))return z.map((H)=>m(H,Z));let L=qH[U];if(L&&z&&Array.isArray(z.data)){let H=z.data.map((D)=>m(D,Z)),T=L({...z,data:H});return F$(T)}if(z&&Array.isArray(z.data))return{...z,data:z.data.map((H)=>m(H,Z))};return m(z,Z)}if(z&&typeof z==="object"&&typeof z.get==="function")return h3(z,Z);return z};if(W&&typeof W.then==="function")return W.then(B);return B(W)}}})}function EH($,Z){let J=["find","first","last","all","firstOrFail","findOrFail","findMany"];for(let Y of J){let G=$[Y];if(typeof G!=="function")continue;$[Y]=function(...V){let U=G.apply(this,V),W=(B)=>Array.isArray(B)?B.map((z)=>m(z,Z)):m(B,Z);if(U&&typeof U.then==="function")return U.then(W);return W(U)}}let Q=["create","firstOrCreate","updateOrCreate","make"];for(let Y of Q){let G=$[Y];if(typeof G!=="function")continue;$[Y]=function(...V){let U=G.apply(this,V),W=(B)=>Array.isArray(B)?B.map((z)=>m(z,Z)):m(B,Z);if(U&&typeof U.then==="function")return U.then(W);return W(U)}}let X=["query","where","orWhere","whereIn","whereNotIn","whereNull","whereNotNull","whereLike","whereBetween","whereNotBetween","orderBy","orderByDesc","select","with","limit","take","skip","latest","oldest"];for(let Y of X){let G=$[Y];if(typeof G!=="function")continue;$[Y]=function(...V){let U=G.apply(this,V);return h3(U,Z)}}}class m3 extends Error{model;id;constructor($,Z){super(Z!=null?`[ORM] ${$} not found for id=${String(Z)}`:`[ORM] No matching ${$} row`);this.name="ModelNotFoundError",this.model=$,this.id=Z}}class K9 extends Error{model;attribute;reason;constructor($,Z,J){let Q=J==="guarded"?`'${Z}' is marked guarded`:`'${Z}' is not in the fillable allowlist`;super(`[ORM] Mass assignment to ${$} forbidden: ${Q}. Use ${$}.forceCreate(...) / .forceUpdate(...) to bypass.`);this.name="MassAssignmentException",this.model=$,this.attribute=Z,this.reason=J}}var FH=new Set(["id","created_at","updated_at","deleted_at","uuid"]);function z8($,Z,J={}){if(J.force)return Z;if(!Z||typeof Z!=="object"||Array.isArray(Z))return Z;let Q=$.attributes;if(!Q)return Z;let X=new Set,Y=new Set,G=new Set;for(let[U,W]of Object.entries(Q)){let B=Z$(U);if(X.add(B),W?.fillable===!0)Y.add(B);if(W?.guarded===!0)G.add(B)}let V=Y.size>0?Y:X;for(let U of Object.keys(Z)){if(FH.has(U))continue;if(G.has(U))throw new K9($.name,U,"guarded");if(U.endsWith("_id"))continue;if(!V.has(U))throw new K9($.name,U,"not-fillable")}return Z}async function H9($,Z){let J=$.set;if(!J||typeof J!=="object")return Z;let Q={...Z};for(let[X,Y]of Object.entries(J)){if(typeof Y!=="function"||!(X in Q))continue;try{Q[X]=await Y(Q)}catch(G){h.error(`[orm] ${$.name}.set.${X} threw \u2014 skipping setter`,G)}}return Q}function CH($,Z){let J=Z.primaryKey||"id",Q=$.create;function X(W){let B=$.where;if(typeof B!=="function")throw Error(`[ORM] ${Z.name}.${W} needs a working where(): the underlying query builder did not expose one`);return B}function Y(W){let B=$.find;if(typeof B!=="function")throw Error(`[ORM] ${Z.name}.${W} needs a working find(): the underlying query builder did not expose one`);return B}function G(W){let B=$.create;if(typeof B!=="function")throw Error(`[ORM] ${Z.name}.${W} cannot create: the underlying query builder did not expose create()`);return B}if(typeof $.update!=="function")$.update=async function(W,B){if(W==null)throw Error(`[ORM] ${Z.name}.update requires an id as the first argument`);if(!B||typeof B!=="object"||Array.isArray(B))throw Error(`[ORM] ${Z.name}.update requires a data object as the second argument`);if(Object.keys(B).length===0){h.debug(`[orm] ${Z.name}.update called with empty data \u2014 short-circuiting and returning current row`);let H=$.find;return typeof H==="function"?await H.call($,W):null}z8(Z,B);let z=await H9(Z,B);await X("update").call($,J,W).update(z);let L=$.find;return typeof L==="function"?await L.call($,W):null};if(typeof $.forceUpdate!=="function")$.forceUpdate=async function(W,B){if(W==null)throw Error(`[ORM] ${Z.name}.forceUpdate requires an id as the first argument`);if(!B||typeof B!=="object"||Array.isArray(B))throw Error(`[ORM] ${Z.name}.forceUpdate requires a data object as the second argument`);let z=await H9(Z,B);await X("forceUpdate").call($,J,W).update(z);let L=$.find;return typeof L==="function"?await L.call($,W):null};if(typeof $.forceCreate!=="function")$.forceCreate=async function(W){if(!W||typeof W!=="object"||Array.isArray(W))throw Error(`[ORM] ${Z.name}.forceCreate requires a data object`);if(typeof Q!=="function")throw Error(`[ORM] ${Z.name}.forceCreate cannot create: the underlying query builder did not expose create()`);return await Q.call($,W)};if(typeof $.delete!=="function")$.delete=async function(W){if(W==null)throw Error(`[ORM] ${Z.name}.delete requires an id as the first argument`);if(!await Y("delete").call($,W))return!1;return await X("delete").call($,J,W).delete(),!0};if(typeof $.findOrFail!=="function")$.findOrFail=async function(W){let B=await Y("findOrFail").call($,W);if(B==null)throw new m3(Z.name,W);return B};if(typeof $.exists!=="function")$.exists=async function(W){if(W==null)return!1;let B=X("exists").call($,J,W);if(typeof B.count==="function"){let L=await B.count();return Number(L)>0}let z=$.find;return typeof z==="function"?await z.call($,W)!=null:!1};if(typeof $.firstOrCreate!=="function")$.firstOrCreate=async function(W,B={}){if(!W||typeof W!=="object"||Array.isArray(W))throw Error(`[ORM] ${Z.name}.firstOrCreate requires a where-attrs object`);let z=X("firstOrCreate").call($,W),L=typeof z.first==="function"?await z.first():await z;if(L)return L;let H={...W,...B};return z8(Z,H),await G("firstOrCreate").call($,H)};if(typeof $.updateOrCreate!=="function")$.updateOrCreate=async function(W,B){if(!W||typeof W!=="object"||Array.isArray(W))throw Error(`[ORM] ${Z.name}.updateOrCreate requires a where-attrs object`);if(!B||typeof B!=="object"||Array.isArray(B))throw Error(`[ORM] ${Z.name}.updateOrCreate requires a values object`);let z=X("updateOrCreate").call($,W),L=typeof z.first==="function"?await z.first():await z;if(L){z8(Z,B);let T=L[J];await X("updateOrCreate").call($,J,T).update(B);let D=$.find;return typeof D==="function"?await D.call($,T):{...L,...B}}let H={...W,...B};return z8(Z,H),await G("updateOrCreate").call($,H)};if(typeof $.count!=="function")$.count=async function(){let W=$;if(typeof W.query==="function"){let L=W.query();if(typeof L?.count==="function"){let H=await L.count();return Number(H)||0}}let{all:B,get:z}=$;if(typeof B==="function")return(await B.call($)||[]).length;if(typeof z==="function")return(await z.call($)||[]).length;return 0};if(typeof $.pluck!=="function")$.pluck=async function(W){if(!W||typeof W!=="string")throw Error(`[ORM] ${Z.name}.pluck requires a column name`);let B=$.all;return((typeof B==="function"?await B.call($):[])||[]).map((L)=>L?.[W])};if(typeof $.whereIn!=="function")$.whereIn=async function(W,B){if(!W||typeof W!=="string")throw Error(`[ORM] ${Z.name}.whereIn requires a column name`);if(!Array.isArray(B))throw Error(`[ORM] ${Z.name}.whereIn requires an array of values`);if(B.length===0)return[];let z=$.where;if(typeof z!=="function")return[];let L=z.call($,W,"in",B);if(L&&typeof L.get==="function")return await L.get();return await L};let V=[["latest","desc"],["oldest","asc"]];for(let[W,B]of V)if(typeof $[W]!=="function")$[W]=async function(z="created_at"){let L=$,H=typeof L.query==="function"?L.query():L;if(typeof H?.orderBy==="function"){let O=H.orderBy(z,B);if(typeof O.first==="function")return await O.first();if(typeof O.get==="function")return(await O.get())?.[0]??null}let T=$.all;if(typeof T!=="function")return null;return[...await T.call($)||[]].sort((O,k)=>{let N=O?.[z],R=k?.[z];if(N===R)return 0;return(N>R?1:-1)*(B==="desc"?-1:1)})[0]??null};let U=u3(Z.traits?.useSearch);if(U){let W=U.index??Z.table??Z$(`${Z.name}s`);if(typeof $.search!=="function")$.search=function(B,z){return kH($,W,B,z)};if(typeof $.makeAllSearchable!=="function")$.makeAllSearchable=async function(B=500){let z=$.all;if(typeof z!=="function")throw Error(`[ORM] ${Z.name}.makeAllSearchable cannot run: the underlying query builder did not expose all()`);let{useSearchEngine:L}=await import("@stacksjs/search-engine"),H=L(),T=0,D=$.query;if(typeof D==="function")try{let k=D.call($);if(k&&typeof k.chunk==="function")return await k.chunk(B,async(N)=>{let R=N.map((M)=>j3(M,U)).filter(Boolean);if(R.length>0)await H.addDocuments(W,R);T+=R.length}),T}catch{}let O=(await z.call($)||[]).map((k)=>j3(k,U)).filter(Boolean);if(O.length>0)await H.addDocuments(W,O);return O.length};if(typeof $.removeAllFromSearch!=="function")$.removeAllFromSearch=async function(){let{useSearchEngine:B}=await import("@stacksjs/search-engine"),z=B();if(typeof z.deleteAllDocuments==="function"){await z.deleteAllDocuments(W);return}let L=$.all,H=typeof L==="function"?await L.call($)||[]:[],T=B();for(let D of H){let q=D?.id??D?._attributes?.id;if(q!=null)await T.deleteDocument(W,Number(q))}}}}function j3($,Z){if(typeof Z.shape==="function")try{return Z.shape($)}catch{return}let J=$?.toSearchableObject?.();if(J!==void 0)return J;return $?._attributes??(typeof $?.toJSON==="function"?$.toJSON():null)}function kH($,Z,J,Q){let X={q:J,...Q??{}},Y={with(G){return X={...X,...G},Y},where(G){return X={...X,filter:G},Y},async get(){let{useSearchEngine:G}=await import("@stacksjs/search-engine");return(await G().search(Z,X))?.hits??[]},async paginate(G,V=1){let{useSearchEngine:U}=await import("@stacksjs/search-engine"),B=await U().search(Z,{...X,limit:G,offset:(V-1)*G});return{hits:B.hits??[],total:Number(B.estimatedTotalHits??B.nbHits??B.total??0),page:V,perPage:G}},async raw(){let{useSearchEngine:G}=await import("@stacksjs/search-engine");return await G().search(Z,X)}};return Y}async function L9($,Z){if(!$||typeof $!=="object")return;let J=$._attributes??$;for(let Q of Z){if(!(Q in J))continue;let X=J[Q];if(!S0(X))continue;J[Q]=await Y$(X)}}function AH($,Z){if(Z.length===0)return;let J=async(G)=>{if(Array.isArray(G)){for(let V of G)await L9(V,Z);return G}if(G&&typeof G==="object"&&Array.isArray(G.data)){for(let V of G.data)await L9(V,Z);return G}if(G)await L9(G,Z);return G},Q=["find","first","last","all","firstOrFail","findOrFail","findMany"];for(let G of Q){let V=$[G];if(typeof V!=="function")continue;$[G]=async function(...U){let W=await V.apply(this,U);return await J(W)}}let X=["create","firstOrCreate","updateOrCreate","make"];for(let G of X){let V=$[G];if(typeof V!=="function")continue;$[G]=async function(...U){let W=await V.apply(this,U);return await J(W)}}let Y=$.update;if(typeof Y==="function")$.update=async function(G,V){let U=await Y.call(this,G,V);return await J(U)}}function NH($,Z){if(Z.length===0)return;let J=async(Y)=>{if(!Y||typeof Y!=="object"||Array.isArray(Y))return Y;let G={...Y};for(let V of Z)if(V in G)G[V]=await X$(G[V]);return G},Q=["create","firstOrCreate","updateOrCreate"];for(let Y of Q){let G=$[Y];if(typeof G!=="function")continue;$[Y]=async function(...V){if(V[0]=await J(V[0]),V[1])V[1]=await J(V[1]);return await G.apply(this,V)}}let X=$.update;if(typeof X==="function")$.update=async function(Y,G){let V=await J(G);return await X.call(this,Y,V)}}function xH($,Z){let J=$.create;if(typeof J==="function")$.create=async function(Q,...X){z8(Z,Q);let Y=await H9(Z,Q);return await J.call(this,Y,...X)};for(let Q of["firstOrCreate","updateOrCreate"]){let X=$[Q];if(typeof X!=="function")continue}}function IH($,Z){let J=["create","firstOrCreate","updateOrCreate"];for(let X of J){let Y=$[X];if(typeof Y==="function")$[X]=async function(...G){if(h.debug(`[orm] ${X.charAt(0).toUpperCase()+X.slice(1)} ${String($.name||"unknown")}`,G[0]),G[0]&&typeof G[0]==="object"&&!Array.isArray(G[0]))G[0]=v3(G[0],Z,"set");return await Y.apply(this,G)}}let Q=$.update;if(typeof Q==="function")$.update=async function(X,Y){let G=Y&&typeof Y==="object"&&!Array.isArray(Y)?v3(Y,Z,"set"):Y;return await Q.call(this,X,G)}}function FF($){h.debug(`[orm] Defining model: ${$.name} (table: ${$.table})`);let Z=PH($),J=RH($),Q=SH(Z,J),X=vH($);$.__traitMethods=X;let Y=Q?{...$,hooks:{...$.hooks,...Q}}:$,G=zH(Y);if(EH(G,$.casts),CH(G,Y),xH(G,Y),$.casts&&Object.keys($.casts).length>0)IH(G,$.casts);let V=G$($);if(V.length>0)NH(G,V),AH(G,V);let U=$.traits?.useSoftDeletes;if(U)yH(G,Y,U);let W=$.traits?.useAudit;if(W){let z=k9(W);A9(G,$.name,$.primaryKey||"id",z)}G.withoutEvents=function(z){return W0(z)};for(let z of["create","update","firstOrCreate","updateOrCreate","forceCreate","forceUpdate","delete","forceDelete","softDelete","restore"]){let L=G[z];if(typeof L!=="function")continue;let H=`${z}Quietly`;if(typeof G[H]==="function")continue;G[H]=function(...T){return W0(()=>L.apply(G,T))}}let B=Object.assign(G,X,{...$,getDefinition:()=>$,_isStacksModel:!0});return LH($.name,B),B}function PH($){let Z=$.traits?.observe;if(!Z)return;let J=$.name.toLowerCase(),Q=(L)=>{let H=L?.attributes;if(!H||typeof H!=="object")return L;let T=$.primaryKey||"id",D={...H};if(D[T]===void 0&&L[T]!==void 0)D[T]=L[T];return D},X=async(L,H)=>{if(U0())return;try{let{dispatch:T}=await import("@stacksjs/events");await T(L,H)}catch(T){if(T&&typeof T==="object"&&"code"in T&&T.code==="MODULE_NOT_FOUND")return;if(console.error(`[ORM] Event '${L}' handler error:`,T),process.env.STACKS_ORM_EVENT_ERRORS!=="swallow")throw T}},Y=$.traits?.broadcastOn,G=$.traits?.broadcastWith,V=typeof Y==="function"&&typeof G==="function",U=async(L,H)=>{if(!V)return;if(U0())return;try{let T=Y(H),D=Array.isArray(T)?T:[T],q=G(H),k=(await import("@stacksjs/realtime").catch(()=>null))?.broadcast;if(typeof k!=="function")return;for(let N of D){if(typeof N!=="string"||N.length===0)continue;await k(N,L,q)}}catch(T){if(T&&typeof T==="object"&&"code"in T&&T.code==="MODULE_NOT_FOUND")return;if(console.error(`[ORM] Broadcast '${L}' handler error:`,T),process.env.STACKS_ORM_BROADCAST_ERRORS==="throw")throw T}},W=async(L,H)=>{if(U0())return!0;try{let{dispatchAsync:T}=await import("@stacksjs/events"),D=await T(L,H);if(Array.isArray(D)&&D.some((q)=>q===!1))return!1}catch(T){if(T&&typeof T==="object"&&"code"in T&&T.code==="MODULE_NOT_FOUND")return!0;if(console.error(`[ORM] Before-event '${L}' handler error:`,T),process.env.STACKS_ORM_EVENT_ERRORS!=="swallow")throw T}return!0},B=Z===!0?["create","update","delete"]:Array.isArray(Z)?Z:[],z={};if(B.includes("create"))z.beforeCreate=async(L)=>{if(h.debug(`[orm] Create ${J}`,L),!await W(`${J}:saving`,L))throw Error(`[ORM] ${J}:saving event cancelled the operation`);if(!await W(`${J}:creating`,L))throw Error(`[ORM] ${J}:creating event cancelled the operation`)},z.afterCreate=async(L)=>{let H=Q(L);await X(`${J}:created`,H),await X(`${J}:saved`,H),await U(`${J}:created`,L)};if(B.includes("update"))z.beforeUpdate=async(L)=>{if(h.debug(`[orm] Update ${J}#${L?.id??"unknown"}`,L),!await W(`${J}:saving`,L))throw Error(`[ORM] ${J}:saving event cancelled the operation`);if(!await W(`${J}:updating`,L))throw Error(`[ORM] ${J}:updating event cancelled the operation`)},z.afterUpdate=async(L)=>{let H=Q(L);await X(`${J}:updated`,H),await X(`${J}:saved`,H),await U(`${J}:updated`,L)};if(B.includes("delete"))z.beforeDelete=async(L)=>{if(h.debug(`[orm] Delete ${J}#${L?.id??"unknown"}`),!await W(`${J}:deleting`,L))throw Error(`[ORM] ${J}:deleting event cancelled the operation`)},z.afterDelete=async(L)=>{await X(`${J}:deleted`,Q(L)),await U(`${J}:deleted`,L)};return z}function SH(...$){let Z={},J=new Set;for(let Q of $){if(!Q)continue;for(let X of Object.keys(Q))J.add(X)}for(let Q of J){let X=$.map((Y)=>Y?.[Q]).filter((Y)=>typeof Y==="function");if(!X.length)continue;Z[Q]=async(...Y)=>{for(let G of X)await G(...Y)}}return Object.keys(Z).length?Z:void 0}function u3($){if(!$)return null;if($===!0)return{};if(typeof $==="object")return $;return null}function RH($){let Z=u3($.traits?.useSearch);if(!Z)return;let J=Z.index??$.table??Z$(`${$.name}s`);function Q(G){if(typeof Z.shape==="function")try{return Z.shape(G)}catch(W){h.warn(`[orm/search] shape() threw for ${$.name}: ${W.message}`);return}let U=m(G).toSearchableObject?.();if(U!==void 0)return U;return G?._attributes??(typeof G?.toJSON==="function"?G.toJSON():null)}let X=async(G)=>{if(U0())return;let V=Q(G);if(!V)return;if(Z.queueable){try{let{Jobs:U}=await import("@stacksjs/queue");await U.dispatch("SyncSearchIndex",{index:J,op:"upsert",doc:V})}catch(U){h.warn(`[orm/search] queue dispatch failed for ${$.name}; falling back to inline: ${U.message}`),await f3(J,V,$.name)}return}await f3(J,V,$.name)};return{afterCreate:X,afterUpdate:X,afterDelete:async(G)=>{if(U0())return;let V=G?.id??G?._attributes?.id;if(V==null)return;if(Z.queueable){try{let{Jobs:U}=await import("@stacksjs/queue");await U.dispatch("SyncSearchIndex",{index:J,op:"delete",id:Number(V)})}catch(U){h.warn(`[orm/search] queue dispatch failed for ${$.name}#${V}; falling back to inline: ${U.message}`),await M3(J,Number(V),$.name)}return}await M3(J,Number(V),$.name)}}}async function f3($,Z,J){try{let{useSearchEngine:Q}=await import("@stacksjs/search-engine");await Q().addDocument($,Z)}catch(Q){h.warn(`[orm/search] Failed to index ${J}: ${Q.message}`)}}async function M3($,Z,J){try{let{useSearchEngine:Q}=await import("@stacksjs/search-engine");await Q().deleteDocument($,Z)}catch(Q){h.warn(`[orm/search] Failed to remove ${J}#${Z}: ${Q.message}`)}}function vH($){let Z={},J=$.table,Q=$.traits;if(!Q)return Z;if(Q.taggable)Z._taggable=f9(J);if(Q.categorizable)Z._categorizable=M9(J);if(Q.commentable)Z._commentable=g9(J);if(Q.billable)Z._billable=N3(J);if(Q.likeable){let Y=typeof Q.likeable==="object"?Q.likeable:void 0;Z._likeable=x3(J,Y)}let X=Q.useAuth||Q.authenticatable;if(typeof X==="object"&&X&&"useTwoFactor"in X&&X.useTwoFactor)Z._twoFactor=I3();return Z}function yH($,Z,J){let Q=P3($,Z.primaryKey||"id"),X=S3(J),Y=Z,G=Z.name.toLowerCase(),V=Z.traits?.observe!=null&&Z.traits?.observe!==!1,U=async(H)=>{if(!V||U0())return!0;try{let{dispatchAsync:T}=await import("@stacksjs/events"),D=await T(`${G}:restoring`,{id:H});if(Array.isArray(D)&&D.some((q)=>q===!1))return!1}catch(T){if(T?.code!=="MODULE_NOT_FOUND")console.error(`[ORM] Before-event '${G}:restoring' handler error:`,T)}return!0},W=async(H)=>{if(!V||U0())return;try{let{dispatch:T}=await import("@stacksjs/events");await T(`${G}:restored`,{id:H})}catch(T){if(T?.code!=="MODULE_NOT_FOUND")console.error(`[ORM] Event '${G}:restored' handler error:`,T)}},B=process.env.STACKS_ORM_CASCADE_SWALLOW!=="true",z=async(H)=>{if(!X.cascade?.length||!B){let D=await Q.softDelete(H);if(D&&X.cascade?.length)await U8(Y,X,H,"softDelete");return D}let{db:T}=await import("@stacksjs/database");return await T.transaction(async()=>{let D=await Q.softDelete(H);if(D)await U8(Y,X,H,"softDelete");return D})},L=async(H)=>{if(!await U(H))return!1;if(!X.cascade?.length||!B){let O=await Q.restore(H);if(O){if(X.cascade?.length)await U8(Y,X,H,"restore");await W(H)}return O}let{db:D}=await import("@stacksjs/database"),q=await D.transaction(async()=>{let O=await Q.restore(H);if(O)await U8(Y,X,H,"restore");return O});if(q)await W(H);return q};$.softDelete=z,$.restore=L,$.forceDelete=Q.forceDelete,$.withTrashed=Q.withTrashed,$.onlyTrashed=Q.onlyTrashed,$.delete=z}function bH($){if($==null)return $;if(Array.isArray($))return $.map(bH);if(typeof $!=="object")return $;if(typeof $.toJSON==="function")return $.toJSON();if($._attributes&&typeof $._attributes==="object")return $._attributes;return $}import{log as jH}from"@stacksjs/logging";import{path as z0}from"@stacksjs/path";import{fs as L8}from"@stacksjs/storage";function L0($){return $.replace(/([A-Z]+)([A-Z][a-z])/g,"$1_$2").replace(/([a-z\d])([A-Z])/g,"$1_$2").replace(/(\d)([A-Za-z])/g,"$1_$2").toLowerCase()}function fH($){let Z=typeof $.type==="string"?$.type.toLowerCase():"",J=(()=>{switch(Z){case"string":case"text":case"longtext":case"mediumtext":case"tinytext":case"char":case"varchar":case"enum":case"uuid":case"date":case"datetime":case"timestamp":case"timestamptz":case"time":case"year":return"string";case"integer":case"int":case"tinyint":case"smallint":case"mediumint":case"float":case"double":case"decimal":case"numeric":return"number";case"bigint":return"number | bigint";case"boolean":case"bool":return"boolean";case"json":case"jsonb":return"unknown";case"binary":case"blob":case"bytea":return"Uint8Array";default:return"unknown"}})();return $.nullable===!0?`${J} | null`:J}function MH($){let Z={},J=$.belongsTo;if(!J)return Z;let Q=Array.isArray(J)?J:Object.keys(J);for(let X of Q)Z[`${L0(X)}_id`]="number";return Z}function _H($,Z){let[J,Q]=[L0($),L0(Z)].sort();return`${J}_${Q}`}function gH($,Z){let J=Z.belongsToMany;if(!J)return[];let Q=[],X=Array.isArray(J)?J:[];for(let Y of X){let G,V,U,W;if(typeof Y==="string")G=Y;else if(Y&&typeof Y==="object"&&"model"in Y){let H=Y;G=H.model,V=H.pivotTable,U=H.firstForeignKey,W=H.secondForeignKey}else continue;let B=V??_H($,G),z=U??`${L0($)}_id`,L=W??`${L0(G)}_id`;Q.push({table:B,columns:{id:"number",[z]:"number",[L]:"number",created_at:"string",updated_at:"string | null"}})}return Q}function hH($){let Z={id:"number"},J=$.traits??{};if(J.useUuid)Z.uuid="string";if((J.useTimestamps??J.timestampable)!==!1)Z.created_at="string",Z.updated_at="string | null";if(J.useSoftDeletes??J.softDeletable)Z.deleted_at="string | null";return Z}function mH($){let Z={},J=$.attributes??{};for(let[Q,X]of Object.entries(J))Z[L0(Q)]=fH(X);return Z}function c3($,Z){let J=Object.entries(Z).map(([Q,X])=>` ${Q}: ${X}`).join(`
13
13
  `);return` ${$}: {
14
14
  // columns
15
15
  ${J}
16
- }`}var qz=`/* eslint-disable */
16
+ }`}var n3=`/* eslint-disable */
17
17
  // AUTO-GENERATED by \`buddy generate:db-types\` \u2014 do not edit.
18
18
  // Regenerate after adding/removing a model or changing its attributes.
19
19
  // See stacksjs/stacks#1923.
20
20
 
21
21
  declare module '@stacksjs/database' {
22
22
  interface DatabaseSchema {
23
- `,Ez=` }
23
+ `,l3=` }
24
24
  }
25
25
 
26
26
  export {}
27
- `;async function Cz($,Z){let J=[];if(!C8.existsSync($))return J;let Y=C8.readdirSync($,{withFileTypes:!0});for(let X of Y){let Q=H0.join($,X.name);if(X.isDirectory()){if(Z){let G=await Cz(Q,!0);J.push(...G)}continue}if(!X.name.endsWith(".ts"))continue;if(X.name.startsWith("_")||X.name.startsWith("index"))continue;try{let G=await import(Q),W=G.default||G;if(W?.name&&(W.attributes||W.table))J.push({filePath:Q,model:W})}catch{}}return J}async function _E($={}){let Z=$.modelsDir??H0.userModelsPath(),J=$.defaultsDir??H0.frameworkPath("defaults/app/Models"),Y=$.outFile??H0.projectPath("database/types.d.ts"),X=[],Q=[];for(let[U,K]of[[Z,!1],[J,!0]])try{let T=await Cz(U,K);Q.push(...T)}catch(T){X.push({file:U,error:T.message})}let G=new Map;for(let U of Q)G.set(U.model.name??H0.basename(U.filePath,".ts"),U);for(let U of Q)if(U.filePath.startsWith(Z))G.set(U.model.name??H0.basename(U.filePath,".ts"),U);let W=[];for(let[U,{model:K}]of G){let T=K.table??`${T0(U)}s`,w={...jE(K),...fE(K),...SE(K)};W.push({table:T,model:U,columns:w})}let L=new Map;for(let[U,{model:K}]of G)for(let T of bE(U,K)){if(L.has(T.table))continue;L.set(T.table,{table:T.table,model:`(${T.table} pivot)`,columns:T.columns})}W.push(...L.values()),W.sort((U,K)=>U.table.localeCompare(K.table));let B=W.map((U)=>Oz(U.table,U.columns)).join(`
28
- `),V=`${qz}${B}
29
- ${Ez}`;if(!$.dryRun){let U=H0.dirname(Y);if(!C8.existsSync(U))C8.mkdirSync(U,{recursive:!0});C8.writeFileSync(Y,V,"utf-8"),vE.success(`[generate:db-types] wrote ${W.length} table(s) to ${Y}`)}return{outFile:Y,tables:W,errors:X,content:V}}function gE($){let Z=[...$].sort((J,Y)=>J.table.localeCompare(Y.table)).map((J)=>Oz(J.table,J.columns)).join(`
30
- `);return`${qz}${Z}
31
- ${Ez}`}import{configureOrm as ME}from"@stacksjs/query-builder";function hE(){try{let $=process.env.DB_DATABASE_PATH||"database/stacks.sqlite";if((process.env.DB_CONNECTION||"sqlite")==="sqlite")ME({database:$})}catch{}}hE();async function D$($,Z=[""]){let{path:J}=await import("@stacksjs/path"),Y=J.userModelsPath(`${$}.ts`);try{if(await Bun.file(Y).exists())return(await import(Y)).default}catch(X){console.error(`[orm] Failed to import userland model ${$} from ${Y} \u2014 falling back to framework default. Reason:`,X)}for(let X of Z){let Q=X?`${X}/`:"",G=J.frameworkPath(`defaults/app/Models/${Q}${$}.ts`);try{if(await Bun.file(G).exists())return(await import(G)).default}catch(W){console.error(`[orm] Failed to import framework default model ${$} from ${G} \u2014 trying next subdir. Reason:`,W)}}return null}var J0={},Fz=()=>{},FI=new Promise(($)=>{Fz=$});function F($){return new Proxy(function(){},{get(Z,J){if(J==="then")return;let Y=J0[$];if(Y==null)return;let X=Y[J];return typeof X==="function"?X.bind(Y):X},set(Z,J,Y){let X=J0[$];if(X==null)return!1;return X[J]=Y,!0},has(Z,J){let Y=J0[$];return Y==null?!1:(J in Y)},apply(Z,J,Y){let X=J0[$];if(X==null||typeof X!=="function")return;return X.apply(J,Y)}})}var mE=F("User"),uE=F("Job"),cE=F("FailedJob"),lE=[["Team",[""],"auth"],["Subscriber",[""],"auth"],["SubscriberEmail",[""],"auth"],["Subscription",[""],"auth"],["Post",["Content"],"cms"],["Page",["Content"],"cms"],["Author",["Content"],"cms"],["Comment",[""],"cms"],["Tag",[""],"cms"],["Activity",[""],"dashboard"],["Deployment",[""],"dashboard"],["Release",[""],"dashboard"],["Notification",[""],"dashboard"],["Log",[""],"dashboard"],["Request",[""],"dashboard"],["Error",[""],"monitoring"],["Websocket",["realtime"],"realtime"],["Campaign",[""],"marketing"],["CampaignSend",[""],"marketing"],["EmailList",[""],"marketing"],["EmailListSubscriber",[""],"marketing"],["SocialPost",[""],"marketing"],["PaymentMethod",[""],"commerce"],["PaymentProduct",[""],"commerce"],["PaymentTransaction",[""],"commerce"],["Order",["commerce"],"commerce"],["OrderItem",["commerce"],"commerce"],["Cart",["commerce"],"commerce"],["CartItem",["commerce"],"commerce"],["Customer",["commerce"],"commerce"],["Product",["commerce"],"commerce"],["ProductVariant",["commerce"],"commerce"],["ProductUnit",["commerce"],"commerce"],["Manufacturer",["commerce"],"commerce"],["Category",["commerce"],"commerce"],["Coupon",["commerce"],"commerce"],["GiftCard",["commerce"],"commerce"],["LicenseKey",["commerce"],"commerce"],["Review",["commerce"],"commerce"],["Receipt",["commerce"],"commerce"],["PrintDevice",["commerce"],"commerce"],["ShippingMethod",["commerce"],"commerce"],["ShippingRate",["commerce"],"commerce"],["ShippingZone",["commerce"],"commerce"],["DeliveryRoute",["commerce"],"commerce"],["DigitalDelivery",["commerce"],"commerce"],["Driver",["commerce"],"commerce"],["TaxRate",["commerce"],"commerce"],["WaitlistProduct",["commerce"],"commerce"],["WaitlistRestaurant",["commerce"],"commerce"],["LoyaltyPoint",["commerce"],"commerce"],["LoyaltyReward",["commerce"],"commerce"],["Payment",["commerce"],"commerce"],["Transaction",["commerce"],"commerce"]];queueMicrotask(async()=>{try{let{feature:$}=await import("@stacksjs/config"),Z=await D$("User");if(Z)J0.User=Z;if($("queue")){let J=await D$("Job");if(J)J0.Job=J;let Y=await D$("FailedJob");if(Y)J0.FailedJob=Y}for(let[J,Y,X]of lE){if(!$(X))continue;let Q=await D$(J,Y);if(Q)J0[J]=Q}}catch($){console.error("[orm] deferred model load failed:",$)}finally{Fz()}});var nE=F("Activity"),pE=F("Author"),dE=F("Campaign"),iE=F("Cart"),aE=F("CartItem"),sE=F("Category"),oE=F("Comment"),rE=F("Coupon"),tE=F("Customer"),eE=F("DeliveryRoute"),$C=F("Deployment"),ZC=F("DigitalDelivery"),JC=F("Driver"),YC=F("CampaignSend"),XC=F("EmailList"),QC=F("EmailListSubscriber"),GC=F("Error"),WC=F("GiftCard"),VC=F("LicenseKey"),BC=F("Log"),LC=F("LoyaltyPoint"),UC=F("LoyaltyReward"),zC=F("Manufacturer"),KC=F("Notification"),HC=F("Order"),TC=F("OrderItem"),wC=F("Page"),DC=F("Payment"),OC=F("PaymentMethod"),qC=F("PaymentProduct"),EC=F("PaymentTransaction"),CC=F("Post"),FC=F("PrintDevice"),kC=F("Product"),xC=F("ProductUnit"),AC=F("ProductVariant"),NC=F("Receipt"),IC=F("Release"),PC=F("Request"),vC=F("Review"),yC=F("ShippingMethod"),SC=F("ShippingRate"),RC=F("ShippingZone"),bC=F("SocialPost"),jC=F("Subscriber"),fC=F("SubscriberEmail"),_C=F("Subscription"),gC=F("Tag"),MC=F("TaxRate"),hC=F("Team"),mC=F("Transaction"),uC=F("WaitlistProduct"),cC=F("WaitlistRestaurant"),lC=F("Websocket"),nC={User:mE,Job:uE,FailedJob:cE,Activity:nE,Author:pE,Campaign:dE,CampaignSend:YC,Cart:iE,CartItem:aE,Category:sE,Comment:oE,Coupon:rE,Customer:tE,DeliveryRoute:eE,Deployment:$C,DigitalDelivery:ZC,Driver:JC,EmailList:XC,EmailListSubscriber:QC,ErrorModel:GC,GiftCard:WC,LicenseKey:VC,Log:BC,LoyaltyPoint:LC,LoyaltyReward:UC,Manufacturer:zC,Notification:KC,Order:HC,OrderItem:TC,Page:wC,Payment:DC,PaymentMethod:OC,PaymentProduct:qC,PaymentTransaction:EC,Post:CC,PrintDevice:FC,Product:kC,ProductUnit:xC,ProductVariant:AC,Receipt:NC,Release:IC,Request:PC,Review:vC,ShippingMethod:yC,ShippingRate:SC,ShippingZone:RC,SocialPost:bC,Subscriber:jC,SubscriberEmail:fC,Subscription:_C,Tag:gC,TaxRate:MC,Team:hC,Transaction:mC,WaitlistProduct:uC,WaitlistRestaurant:cC,Websocket:lC},S0=globalThis;for(let[$,Z]of Object.entries(nC))if(Z&&S0[$]===void 0)S0[$]=Z;async function pC($){if(!$)return[];try{if(typeof $.all==="function"){let Z=await $.all();return Array.isArray(Z)?Z:[]}if(typeof $.get==="function"){let Z=await $.get();return Array.isArray(Z)?Z:[]}}catch{}return[]}function dC($,Z,J=""){if(!$)return J;try{if(typeof $.get==="function"){let X=$.get(Z);if(X!==void 0&&X!==null)return X}}catch{}let Y=$?.[Z];return Y!==void 0&&Y!==null?Y:J}if(S0.safeAll===void 0)S0.safeAll=pC;if(S0.safeGet===void 0)S0.safeGet=dC;export{z0 as withoutEvents,wF as transactional,HF as transactionBuilder,KF as transaction,gF as toTimestamp,S$ as toSimplePaginator,y$ as toPaginator,R$ as toCursorPaginator,PE as toAttrs,hz as setAuditUser,TF as savepoint,j$ as resolvePageArgs,f$ as resolveCursorArgs,gE as renderDatabaseTypeFile,Rz as prunable,E4 as parseCursor,FI as ormReady,FF as modelTableName,oC as massPrunable,uz as mapWriteError,RF as mapEntity,z4 as isUniqueViolation,rz as isSimplePaginator,oz as isPaginator,b0 as isEncrypted,tz as isCursorPaginator,kF as hasRelations,c as getTableName,dz as getRelations,xF as getRelationType,AF as getRelationCount,rC as getPrunableConfig,NF as getPivotTables,pz as getPivotTableName,_0 as getModelName,PF as getHiddenAttributes,vF as getGuardedAttributes,yF as getFillableAttributes,fF as formatDate,P$ as findUserModel,I$ as findCoreModel,IF as fetchOtherModelRelations,bF as extractImports,SF as extractFields,_F as extractDate,jF as extractAttributesFromModel,_$ as enrichPaginatorUrls,q$ as encryptValue,HI as defineModel,E$ as decryptValue,LF as db,B4 as createAuditMethods,C$ as collectEncryptedAttributes,_E as buildDatabaseSchema,GF as batchLoad,lC as Websocket,cC as WaitlistRestaurant,uC as WaitlistProduct,mE as User,mC as Transaction,hC as Team,MC as TaxRate,gC as Tag,_C as Subscription,fC as SubscriberEmail,jC as Subscriber,lz as SubqueryBuilder,bC as SocialPost,RC as ShippingZone,SC as ShippingRate,yC as ShippingMethod,vC as Review,PC as Request,IC as Release,NC as Receipt,AC as ProductVariant,xC as ProductUnit,kC as Product,FC as PrintDevice,CC as Post,EC as PaymentTransaction,qC as PaymentProduct,OC as PaymentMethod,DC as Payment,wC as Page,TC as OrderItem,HC as Order,KC as Notification,wz as ModelNotFoundError,$4 as MassAssignmentException,zC as Manufacturer,UC as LoyaltyReward,LC as LoyaltyPoint,BC as Log,VC as LicenseKey,uE as Job,WC as GiftCard,cE as FailedJob,GC as ErrorModel,QC as EmailListSubscriber,XC as EmailList,JC as Driver,ZC as DigitalDelivery,$C as Deployment,eE as DeliveryRoute,tE as Customer,rE as Coupon,oE as Comment,sE as Category,aE as CartItem,iE as Cart,YC as CampaignSend,dE as Campaign,pE as Author,nE as Activity};
27
+ `;async function p3($,Z){let J=[];if(!L8.existsSync($))return J;let Q=L8.readdirSync($,{withFileTypes:!0});for(let X of Q){let Y=z0.join($,X.name);if(X.isDirectory()){if(Z){let G=await p3(Y,!0);J.push(...G)}continue}if(!X.name.endsWith(".ts"))continue;if(X.name.startsWith("_")||X.name.startsWith("index"))continue;try{let G=await import(Y),V=G.default||G;if(V?.name&&(V.attributes||V.table))J.push({filePath:Y,model:V})}catch{}}return J}async function uH($={}){let Z=$.modelsDir??z0.userModelsPath(),J=$.defaultsDir??z0.frameworkPath("defaults/app/Models"),Q=$.outFile??z0.projectPath("database/types.d.ts"),X=[],Y=[];for(let[z,L]of[[Z,!1],[J,!0]])try{let H=await p3(z,L);Y.push(...H)}catch(H){X.push({file:z,error:H.message})}let G=new Map;for(let z of Y)G.set(z.model.name??z0.basename(z.filePath,".ts"),z);for(let z of Y)if(z.filePath.startsWith(Z))G.set(z.model.name??z0.basename(z.filePath,".ts"),z);let V=[];for(let[z,{model:L}]of G){let H=L.table??`${L0(z)}s`,T={...hH(L),...mH(L),...MH(L)};V.push({table:H,model:z,columns:T})}let U=new Map;for(let[z,{model:L}]of G)for(let H of gH(z,L)){if(U.has(H.table))continue;U.set(H.table,{table:H.table,model:`(${H.table} pivot)`,columns:H.columns})}V.push(...U.values()),V.sort((z,L)=>z.table.localeCompare(L.table));let W=V.map((z)=>c3(z.table,z.columns)).join(`
28
+ `),B=`${n3}${W}
29
+ ${l3}`;if(!$.dryRun){let z=z0.dirname(Q);if(!L8.existsSync(z))L8.mkdirSync(z,{recursive:!0});L8.writeFileSync(Q,B,"utf-8"),jH.success(`[generate:db-types] wrote ${V.length} table(s) to ${Q}`)}return{outFile:Q,tables:V,errors:X,content:B}}function cH($){let Z=[...$].sort((J,Q)=>J.table.localeCompare(Q.table)).map((J)=>c3(J.table,J.columns)).join(`
30
+ `);return`${n3}${Z}
31
+ ${l3}`}import{configureOrm as nH}from"@stacksjs/query-builder";function lH(){try{let $=process.env.DB_DATABASE_PATH||"database/stacks.sqlite";if((process.env.DB_CONNECTION||"sqlite")==="sqlite")nH({database:$})}catch{}}lH();async function J$($,Z=[""]){let{path:J}=await import("@stacksjs/path"),Q=J.userModelsPath(`${$}.ts`);try{if(await Bun.file(Q).exists())return(await import(Q)).default}catch(X){console.error(`[orm] Failed to import userland model ${$} from ${Q} \u2014 falling back to framework default. Reason:`,X)}for(let X of Z){let Y=X?`${X}/`:"",G=J.frameworkPath(`defaults/app/Models/${Y}${$}.ts`);try{if(await Bun.file(G).exists())return(await import(G)).default}catch(V){console.error(`[orm] Failed to import framework default model ${$} from ${G} \u2014 trying next subdir. Reason:`,V)}}return null}var $0={},d3=()=>{},SF=new Promise(($)=>{d3=$});function F($){return new Proxy(function(){},{get(Z,J){if(J==="then")return;let Q=$0[$];if(Q==null)return;let X=Q[J];return typeof X==="function"?X.bind(Q):X},set(Z,J,Q){let X=$0[$];if(X==null)return!1;return X[J]=Q,!0},has(Z,J){let Q=$0[$];return Q==null?!1:(J in Q)},apply(Z,J,Q){let X=$0[$];if(X==null||typeof X!=="function")return;return X.apply(J,Q)}})}var pH=F("User"),dH=F("Job"),iH=F("FailedJob"),aH=[["Team",[""],"auth"],["Subscriber",[""],"auth"],["SubscriberEmail",[""],"auth"],["Subscription",[""],"auth"],["Post",["Content"],"cms"],["Page",["Content"],"cms"],["Author",["Content"],"cms"],["Comment",[""],"cms"],["Tag",[""],"cms"],["Activity",[""],"dashboard"],["Deployment",[""],"dashboard"],["Release",[""],"dashboard"],["Notification",[""],"dashboard"],["Log",[""],"dashboard"],["Request",[""],"dashboard"],["Error",[""],"monitoring"],["Websocket",["realtime"],"realtime"],["Campaign",[""],"marketing"],["CampaignSend",[""],"marketing"],["EmailList",[""],"marketing"],["EmailListSubscriber",[""],"marketing"],["SocialPost",[""],"marketing"],["PaymentMethod",[""],"commerce"],["PaymentProduct",[""],"commerce"],["PaymentTransaction",[""],"commerce"],["Order",["commerce"],"commerce"],["OrderItem",["commerce"],"commerce"],["Cart",["commerce"],"commerce"],["CartItem",["commerce"],"commerce"],["Customer",["commerce"],"commerce"],["Product",["commerce"],"commerce"],["ProductVariant",["commerce"],"commerce"],["ProductUnit",["commerce"],"commerce"],["Manufacturer",["commerce"],"commerce"],["Category",["commerce"],"commerce"],["Coupon",["commerce"],"commerce"],["GiftCard",["commerce"],"commerce"],["LicenseKey",["commerce"],"commerce"],["Review",["commerce"],"commerce"],["Receipt",["commerce"],"commerce"],["PrintDevice",["commerce"],"commerce"],["ShippingMethod",["commerce"],"commerce"],["ShippingRate",["commerce"],"commerce"],["ShippingZone",["commerce"],"commerce"],["DeliveryRoute",["commerce"],"commerce"],["DigitalDelivery",["commerce"],"commerce"],["Driver",["commerce"],"commerce"],["TaxRate",["commerce"],"commerce"],["WaitlistProduct",["commerce"],"commerce"],["WaitlistRestaurant",["commerce"],"commerce"],["LoyaltyPoint",["commerce"],"commerce"],["LoyaltyReward",["commerce"],"commerce"],["Payment",["commerce"],"commerce"],["Transaction",["commerce"],"commerce"]];queueMicrotask(async()=>{try{let{feature:$}=await import("@stacksjs/config"),Z=await J$("User");if(Z)$0.User=Z;if($("queue")){let J=await J$("Job");if(J)$0.Job=J;let Q=await J$("FailedJob");if(Q)$0.FailedJob=Q}for(let[J,Q,X]of aH){if(!$(X))continue;let Y=await J$(J,Q);if(Y)$0[J]=Y}}catch($){console.error("[orm] deferred model load failed:",$)}finally{d3()}});var oH=F("Activity"),sH=F("Author"),rH=F("Campaign"),tH=F("Cart"),eH=F("CartItem"),$w=F("Category"),Zw=F("Comment"),Jw=F("Coupon"),Qw=F("Customer"),Xw=F("DeliveryRoute"),Yw=F("Deployment"),Gw=F("DigitalDelivery"),Vw=F("Driver"),Bw=F("CampaignSend"),Ww=F("EmailList"),Uw=F("EmailListSubscriber"),zw=F("Error"),Lw=F("GiftCard"),Kw=F("LicenseKey"),Hw=F("Log"),ww=F("LoyaltyPoint"),Tw=F("LoyaltyReward"),Dw=F("Manufacturer"),Ow=F("Notification"),qw=F("Order"),Ew=F("OrderItem"),Fw=F("Page"),Cw=F("Payment"),kw=F("PaymentMethod"),Aw=F("PaymentProduct"),Nw=F("PaymentTransaction"),xw=F("Post"),Iw=F("PrintDevice"),Pw=F("Product"),Sw=F("ProductUnit"),Rw=F("ProductVariant"),vw=F("Receipt"),yw=F("Release"),bw=F("Request"),jw=F("Review"),fw=F("ShippingMethod"),Mw=F("ShippingRate"),_w=F("ShippingZone"),gw=F("SocialPost"),hw=F("Subscriber"),mw=F("SubscriberEmail"),uw=F("Subscription"),cw=F("Tag"),nw=F("TaxRate"),lw=F("Team"),pw=F("Transaction"),dw=F("WaitlistProduct"),iw=F("WaitlistRestaurant"),aw=F("Websocket"),ow={User:pH,Job:dH,FailedJob:iH,Activity:oH,Author:sH,Campaign:rH,CampaignSend:Bw,Cart:tH,CartItem:eH,Category:$w,Comment:Zw,Coupon:Jw,Customer:Qw,DeliveryRoute:Xw,Deployment:Yw,DigitalDelivery:Gw,Driver:Vw,EmailList:Ww,EmailListSubscriber:Uw,ErrorModel:zw,GiftCard:Lw,LicenseKey:Kw,Log:Hw,LoyaltyPoint:ww,LoyaltyReward:Tw,Manufacturer:Dw,Notification:Ow,Order:qw,OrderItem:Ew,Page:Fw,Payment:Cw,PaymentMethod:kw,PaymentProduct:Aw,PaymentTransaction:Nw,Post:xw,PrintDevice:Iw,Product:Pw,ProductUnit:Sw,ProductVariant:Rw,Receipt:vw,Release:yw,Request:bw,Review:jw,ShippingMethod:fw,ShippingRate:Mw,ShippingZone:_w,SocialPost:gw,Subscriber:hw,SubscriberEmail:mw,Subscription:uw,Tag:cw,TaxRate:nw,Team:lw,Transaction:pw,WaitlistProduct:dw,WaitlistRestaurant:iw,Websocket:aw},I0=globalThis;for(let[$,Z]of Object.entries(ow))if(Z&&I0[$]===void 0)I0[$]=Z;async function sw($){if(!$)return[];try{if(typeof $.all==="function"){let Z=await $.all();return Array.isArray(Z)?Z:[]}if(typeof $.get==="function"){let Z=await $.get();return Array.isArray(Z)?Z:[]}}catch{}return[]}function rw($,Z,J=""){if(!$)return J;try{if(typeof $.get==="function"){let X=$.get(Z);if(X!==void 0&&X!==null)return X}}catch{}let Q=$?.[Z];return Q!==void 0&&Q!==null?Q:J}if(I0.safeAll===void 0)I0.safeAll=sw;if(I0.safeGet===void 0)I0.safeGet=rw;export{W0 as withoutEvents,FT as transactional,qT as transactionBuilder,OT as transaction,cT as toTimestamp,T$ as toSimplePaginator,w$ as toPaginator,D$ as toCursorPaginator,bH as toAttrs,WB as setAuditUser,ET as savepoint,q$ as resolvePageArgs,E$ as resolveCursorArgs,cH as renderDatabaseTypeFile,JB as prunable,b9 as parseCursor,SF as ormReady,IT as modelTableName,ZT as massPrunable,zB as mapWriteError,_T as mapEntity,N9 as isUniqueViolation,FB as isSimplePaginator,EB as isPaginator,S0 as isEncrypted,CB as isCursorPaginator,PT as hasRelations,u as getTableName,TB as getRelations,ST as getRelationType,RT as getRelationCount,JT as getPrunableConfig,vT as getPivotTables,wB as getPivotTableName,y0 as getModelName,bT as getHiddenAttributes,jT as getGuardedAttributes,fT as getFillableAttributes,mT as formatDate,K$ as findUserModel,L$ as findCoreModel,yT as fetchOtherModelRelations,gT as extractImports,MT as extractFields,uT as extractDate,hT as extractAttributesFromModel,F$ as enrichPaginatorUrls,X$ as encryptValue,FF as defineModel,Y$ as decryptValue,wT as db,C9 as createAuditMethods,G$ as collectEncryptedAttributes,uH as buildDatabaseSchema,zT as batchLoad,aw as Websocket,iw as WaitlistRestaurant,dw as WaitlistProduct,pH as User,pw as Transaction,lw as Team,nw as TaxRate,cw as Tag,uw as Subscription,mw as SubscriberEmail,hw as Subscriber,KB as SubqueryBuilder,gw as SocialPost,_w as ShippingZone,Mw as ShippingRate,fw as ShippingMethod,jw as Review,bw as Request,yw as Release,vw as Receipt,Rw as ProductVariant,Sw as ProductUnit,Pw as Product,Iw as PrintDevice,xw as Post,Nw as PaymentTransaction,Aw as PaymentProduct,kw as PaymentMethod,Cw as Payment,Fw as Page,Ew as OrderItem,qw as Order,Ow as Notification,m3 as ModelNotFoundError,K9 as MassAssignmentException,Dw as Manufacturer,Tw as LoyaltyReward,ww as LoyaltyPoint,Hw as Log,Kw as LicenseKey,dH as Job,Lw as GiftCard,iH as FailedJob,zw as ErrorModel,Uw as EmailListSubscriber,Ww as EmailList,Vw as Driver,Gw as DigitalDelivery,Yw as Deployment,Xw as DeliveryRoute,Qw as Customer,Jw as Coupon,Zw as Comment,$w as Category,eH as CartItem,tH as Cart,Bw as CampaignSend,rH as Campaign,sH as Author,oH as Activity};