PageSourceSearch

https://www.ultrapremiumdirect.com/_nuxt/WlV9l2j7.js

js ultrapremiumdirect.com collected 2026-09-24 10:44:52 UTC 5,066 bytes, 1 lines download raw bytes

1import{Et as e,F as t,L as n,M as r,St as i,j as a,vt as o}from"./CoeSuB_p.js";import{a as s,l as c,t as l}from"./DQYSlu0p.js";import{n as u,t as d}from"./Dz5cJLU9.js";o(),n();var f=()=>{let{promisedToken:n}=l(),{fetch:o}=c(),f=e(!1),{getQueryListDataGTM:p}=s(),m={PAYZEN:u(),CHECKOUTCOM_CB:d(),CHECKOUTCOM_CB_NL:d()};async function h(e,{variant:t,quantity:r,upsell:i,crossSell:a,sourceItemList:s,traceId:c}){let l=await n();return await o(`/shop/subscription-orders/${e}/items`,{jwtToken:l,fetchOptions:{method:`PATCH`,body:{variant:t,quantity:r,upsell:i,crossSell:a,sourceItemList:s?p({sourceItemList:s}):void 0,traceId:c},headers:{"Content-type":`application/merge-patch+json`}}})}async function g(){let e=await n();return await o(`/shop/subscriptions`,{jwtToken:e})}async function _(e){let t=await n();return await o(`/shop/subscriptions/${e}`,{jwtToken:t})}async function v(e){return _(e).then(e=>e?.subscriptionOrders||[])}async function y(e,s,c){let l=await n();return await o(`/shop/payment-methods?paymentId=${e}&tokenValue=${s}`,{jwtToken:l,transform:e=>e[`hydra:member`].map(e=>({paymentMethod:e}))}).then(async e=>{let n=[];for(let o of e)if(Object.hasOwn(m,o.paymentMethod.code)){let e=m[o.paymentMethod.code];if(!e?.isAvailable){console.log(`${o.paymentMethod.code}.isAvailable() is not available`,e);continue}let s=!1;try{s=await e?.isAvailable()===!0}catch(e){console.error(e);continue}s&&n.push({...o,submit:(...e)=>c(o.paymentMethod,...e),componentLoader:i(a(()=>e?.getComponent()?.catch(e=>(console.error(`Component loading error`,e),r({render:()=>t(`div`,{style:{display:`none`}},`Invalid component loading`)})))))})}return n})}async function b({code:e,interval:t,shippingDate:r}){if(isNaN(t))return;let i=await n();return await o(`/shop/subscriptions/${e}/interval-shipping-date`,{jwtToken:i,fetchOptions:{method:`PATCH`,body:{interval:t,shippingDate:r?`${r.getFullYear()}-${String(r.getMonth()+1).padStart(2,`0`)}-${String(r.getDate()).padStart(2,`0`)}`:null},headers:{"Content-type":`application/merge-patch+json`}}})}async function x(e,t){let r=await n();return await o(`/shop/subscriptions/${e}/bank-details`,{jwtToken:r,fetchOptions:{method:`PATCH`,body:{instrument:t.instrument[`@id`]},headers:{"Content-type":`application/merge-patch+json`}}})}async function S({code:e}){let t=await n();return await o(`/shop/subscriptions/${e}/shipping-dates-range`,{jwtToken:t})}async function C(e,t,r){let i=await n();return t===0?o(`shop/subscriptions/${r}/draft-order/items/${e.id}`,{jwtToken:i,fetchOptions:{method:`DELETE`,headers:{"Content-type":`application/merge-patch+json`}}}):o(`shop/subscriptions/${r}/draft-order/items`,{jwtToken:i,fetchOptions:{method:`PATCH`,body:{quantity:t,orderItem:e[`@id`]},headers:{"Content-type":`application/merge-patch+json`}}}).then(e=>e.draftOrder)}async function w({code:e,billingAddress:t,sameAsShippingAddress:r}){let i=await n();return await o(`/shop/subscriptions/${e}/billing-address`,{jwtToken:i,fetchOptions:{method:`PATCH`,body:{billingAddress:t,sameAsShippingAddress:r},headers:{"Content-type":`application/merge-patch+json`}}})}async function T({code:e,shippingAddress:t,billingAddress:r,pickupPoint:i,shippingMethod:a,billingAddressSameAsShippingAddress:s}){let c=await n();return await o(`/shop/subscriptions/${e}/shipping`,{jwtToken:c,fetchOptions:{method:`PATCH`,body:{billingAddress:r,shippingAddress:t,pickupPoint:i,shippingMethod:a,billingAddressSameAsShippingAddress:s,spreadOnSubscriptionOrder:!0},headers:{"Content-type":`application/merge-patch+json`}}})}async function E({tokenValue:e,values:t}){let r=await n();return await o(`/shop/subscription-orders/${e}/shipping`,{jwtToken:r,fetchOptions:{method:`PATCH`,body:{...t},headers:{"Content-type":`application/merge-patch+json`}}})}async function D(e,t){let r=await n();return await o(`/shop/subscriptions/${t}/shipping-methods?addressId=${e}`,{jwtToken:r,transform:e=>e[`hydra:member`].map(e=>({shippingMethod:e}))})}async function O({code:e}){let t=await n();return await o(`/shop/subscriptions/${e}/force-payment`,{jwtToken:t,fetchOptions:{method:`PATCH`,body:{},headers:{"Content-type":`application/merge-patch+json`}}})}async function k(e){try{f.value=!0;let t=await n(),r=await o(`/shop/payment-instruments`,{jwtToken:t,fetchOptions:{method:`POST`,body:{}}});return r?.[`@id`]?o(`${r[`@id`].replace(`/api/v2`,``)}/method`,{jwtToken:t,fetchOptions:{method:`PATCH`,body:{paymentMethod:`/api/v2/shop/payment-methods/${e}`}}}).then(e=>e):void 0}catch(e){console.error(e)}finally{f.value=!1}}return{paymentMethodApplying:f,paymentMethods:m,addProductToNextDraftOrder:h,getSubscription:_,getSubscriptions:g,getSubscriptionOrders:v,getSubscriptionShippingDate:S,getAvailableSubscriptionPaymentMethods:y,updateSubscriptionIntervalAndShipping:b,updateSubscriptionBankDetail
1s:x,modifyProductToNextDraftOrder:C,updateSubscriptionBillingAddress:w,updateSubscriptionShippingAddress:T,setSubscriptionDraftOrderAddresses:E,loadAvailableSubscriptionShippingMethods:D,setSubscriptionForcePayment:O,submitSubscriptionPaymentMethod:k}};export{f as t};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.