(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,949920,e=>{"use strict";var t=e.i(381477);let r=(0,e.i(66396).withMiddleware)(t.default,e=>(t,r,s)=>(s.revalidateOnFocus=!1,s.revalidateIfStale=!1,s.revalidateOnReconnect=!1,e(t,r,s)));e.s(["default",0,r])},479252,(e,t,r)=>{"use strict";var s,n;Object.defineProperty(r,"__esModule",{value:!0}),r.HttpMethod=void 0,(n=s||(r.HttpMethod=s={})).GET="GET",n.POST="POST",n.PUT="PUT",n.DELETE="DELETE",n.PATCH="PATCH"},212840,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.AccountAPI=void 0;let s=e.r(479252);r.AccountAPI=class{requestHandler;constructor(e){this.requestHandler=e}async getAccount(){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/account"})}async updateAccount(e){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/account",data:e})}async getAccountId(){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/account/id"})}async changeEmail(e){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/email/change",data:{email:e}})}async changePassword(e,t){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/password/change",data:{old_password:e,new_password:t}})}async forgotPassword(e,t,r){let n={};t&&(n.reset_password_url=t),r&&(n.platform=r),await this.requestHandler.request({method:s.HttpMethod.POST,path:"/password/forgotten",data:{email:e},params:n,requiresAuth:!1})}async resetPassword(e,t,r,n){let i={};n&&(i.platform=n),await this.requestHandler.request({method:s.HttpMethod.POST,path:"/password/reset",data:{email:e,otp:t,password:r},params:i,requiresAuth:!1})}async getUserId(){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/user/id"})}async getUserInfo(){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/user/id/email"})}async getUserAccountById(e){return this.requestHandler.request({method:s.HttpMethod.GET,path:`/users/${e}/account`})}async getUserAccountByEmail(e){return this.requestHandler.request({method:s.HttpMethod.GET,path:`/users/email/${encodeURIComponent(e)}/account`})}async updateAccountLockStatus(e,t){await this.requestHandler.request({method:s.HttpMethod.PUT,path:`/users/${e}/account/lockStatus`,data:{accountLockStatus:t}})}}},688029,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.ApplicationsAPI=void 0;let s=e.r(479252);r.ApplicationsAPI=class{requestHandler;constructor(e){this.requestHandler=e}async getApplications(e,t){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/applications",params:{appId:e,endpointId:t}})}async createApplication(e){await this.requestHandler.request({method:s.HttpMethod.POST,path:"/applications",data:e})}async addPartner(e,t,r){await this.requestHandler.request({method:s.HttpMethod.PUT,path:`/applications/app-id/${e}/endpoint-id/${t}`,data:r})}async deletePartner(e,t,r){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:`/applications/partner/app-id/${e}/endpoint-id/${t}`,params:{partner:r}})}async updateLastActivity(e,t,r){await this.requestHandler.request({method:s.HttpMethod.PUT,path:`/applications/activity/user/${e}/app-id/${t}/endpoint-id/${r}`})}async getUserApplications(e){return this.requestHandler.request({method:s.HttpMethod.GET,path:`/applications/user/${e}`})}async createUserApplication(e,t){await this.requestHandler.request({method:s.HttpMethod.POST,path:`/applications/user/${e}`,data:t})}async deleteUserApplications(e){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:`/applications/user/${e}`})}async deleteUserApplication(e,t,r){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:`/applications/user/${e}/app-id/${t}/endpoint-id/${r}`})}async getUserEndpointIds(e){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/applications/endpoint-ids",params:{userID:e}})}}},750413,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.AssetsAPI=void 0;let s=e.r(479252);r.AssetsAPI=class{requestHandler;constructor(e){this.requestHandler=e}async getAssets(){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/assets"})}async getUserAssets(e){return this.requestHandler.request({method:s.HttpMethod.GET,path:`/assets/${e}`})}async deleteUserAssets(e){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:`/assets/${e}`})}async createWUAssets(e,t){await this.requestHandler.request({method:s.HttpMethod.POST,path:`/assets/wu/${e}`,data:t})}async updateWUAssets(e,t){await this.requestHandler.request({method:s.HttpMethod.PUT,path:`/assets/wu/${e}`,data:t})}async createWUAssetsMigration(e,t){await this.requestHandler.request({method:s.HttpMethod.POST,path:`/assets/migration/${e}`,data:t})}}},217083,(e,t,r)=>{var s={675:function(e,t){"use strict";t.byteLength=function(e){var t=u(e),r=t[0],s=t[1];return(r+s)*3/4-s},t.toByteArray=function(e){var t,r,i=u(e),o=i[0],a=i[1],h=new n((o+a)*3/4-a),d=0,p=a>0?o-4:o;for(r=0;r

>16&255,h[d++]=t>>8&255,h[d++]=255&t;return 2===a&&(t=s[e.charCodeAt(r)]>4,h[d++]=255&t),1===a&&(t=s[e.charCodeAt(r)]>2,h[d++]=t>>8&255,h[d++]=255&t),h},t.fromByteArray=function(e){for(var t,s=e.length,n=s%3,i=[],o=0,a=s-n;o>18&63]+r[n>>12&63]+r[n>>6&63]+r[63&n]);return i.join("")}(e,o,o+16383>a?a:o+16383));return 1===n?i.push(r[(t=e[s-1])>>2]+r[t>10]+r[t>>4&63]+r[ttypeof Uint8Array?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",o=0,a=i.length;o0)throw Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");-1===r&&(r=t);var s=r===t?0:4-r%4;return[r,s]}s[45]=62,s[95]=63},72:function(e,t,r){"use strict";var s=r(675),n=r(783),i="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;function o(e){if(e>0x7fffffff)throw RangeError('The value "'+e+'" is invalid for option "size"');var t=new Uint8Array(e);return Object.setPrototypeOf(t,a.prototype),t}function a(e,t,r){if("number"==typeof e){if("string"==typeof t)throw TypeError('The "string" argument must be of type string. Received type number');return d(e)}return u(e,t,r)}function u(e,t,r){if("string"==typeof e){var s=e,n=t;if(("string"!=typeof n||""===n)&&(n="utf8"),!a.isEncoding(n))throw TypeError("Unknown encoding: "+n);var i=0|l(s,n),u=o(i),h=u.write(s,n);return h!==i&&(u=u.slice(0,h)),u}if(ArrayBuffer.isView(e))return p(e);if(null==e)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(S(e,ArrayBuffer)||e&&S(e.buffer,ArrayBuffer)||"u">typeof SharedArrayBuffer&&(S(e,SharedArrayBuffer)||e&&S(e.buffer,SharedArrayBuffer)))return function(e,t,r){var s;if(ttypeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return a.from(e[Symbol.toPrimitive]("string"),t,r);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function h(e){if("number"!=typeof e)throw TypeError('"size" argument must be of type number');if(etypeof console&&"function"==typeof console.error&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(a.prototype,"parent",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.buffer}}),Object.defineProperty(a.prototype,"offset",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.byteOffset}}),a.poolSize=8192,a.from=function(e,t,r){return u(e,t,r)},Object.setPrototypeOf(a.prototype,Uint8Array.prototype),Object.setPrototypeOf(a,Uint8Array),a.alloc=function(e,t,r){return(h(e),e=0x7fffffff)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x7fffffff bytes");return 0|e}function l(e,t){if(a.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||S(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);var r=e.length,s=arguments.length>2&&!0===arguments[2];if(!s&&0===r)return 0;for(var n=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return b(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return M(e).length;default:if(n)return s?-1:b(e).length;t=(""+t).toLowerCase(),n=!0}}function f(e,t,r){var n,i,o,a=!1;if((void 0===t||tthis.length||((void 0===r||r>this.length)&&(r=this.length),r>>=0)>>=0)))return"";for(e||(e="utf8");;)switch(e){case"hex":return function(e,t,r){var s=e.length;(!t||ts)&&(r=s);for(var n="",i=t;i0x7fffffff?r=0x7fffffff:r=e.length)if(n)return -1;else r=e.length-1;else if(ra&&(r=a-u),i=r;i>=0;i--){for(var p=!0,c=0;cr&&(e+=" ... "),""},i&&(a.prototype[i]=a.prototype.inspect),a.prototype.compare=function(e,t,r,s,n){if(S(e,Uint8Array)&&(e=a.from(e,e.offset,e.byteLength)),!a.isBuffer(e))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===s&&(s=0),void 0===n&&(n=this.length),te.length||sthis.length)throw RangeError("out of range index");if(s>=n&&t>=r)return 0;if(s>=n)return -1;if(t>=r)return 1;if(t>>>=0,r>>>=0,s>>>=0,n>>>=0,this===e)return 0;for(var i=n-s,o=r-t,u=Math.min(i,o),h=this.slice(s,n),d=e.slice(t,r),p=0;p239?4:h>223?3:h>191?2:1;if(n+p127&&(d=u);break;case 3:i=e[n+1],o=e[n+2],(192&i)==128&&(192&o)==128&&(u=(15&h)2047&&(u57343)&&(d=u);break;case 4:i=e[n+1],o=e[n+2],a=e[n+3],(192&i)==128&&(192&o)==128&&(192&a)==128&&(u=(15&h)65535&&u65535&&(d-=65536,s.push(d>>>10&1023|55296),d=56320|1023&d),s.push(d),n+=p}var c=s,l=c.length;if(lr)throw RangeError("Trying to access beyond buffer length")}function w(e,t,r,s,n,i){if(!a.isBuffer(e))throw TypeError('"buffer" argument must be a Buffer instance');if(t>n||te.length)throw RangeError("Index out of range")}function P(e,t,r,s,n,i){if(r+s>e.length||r>>=0,i||P(e,t,r,4,34028234663852886e22,-34028234663852886e22),n.write(e,t,r,s,23,4),r+4}function T(e,t,r,s,i){return t*=1,r>>>=0,i||P(e,t,r,8,17976931348623157e292,-17976931348623157e292),n.write(e,t,r,s,52,8),r+8}a.prototype.write=function(e,t,r,s){if(void 0===t)s="utf8",r=this.length,t=0;else if(void 0===r&&"string"==typeof t)s=t,r=this.length,t=0;else if(isFinite(t))t>>>=0,isFinite(r)?(r>>>=0,void 0===s&&(s="utf8")):(s=r,r=void 0);else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var n,i,o,a,u,h,d,p,c=this.length-t;if((void 0===r||r>c)&&(r=c),e.length>0&&(rthis.length)throw RangeError("Attempt to write outside buffer bounds");s||(s="utf8");for(var l=!1;;)switch(s){case"hex":return function(e,t,r,s){r=Number(r)||0;var n=e.length-r;s?(s=Number(s))>n&&(s=n):s=n;var i=t.length;s>i/2&&(s=i/2);for(var o=0;o>8,n.push(r%256),n.push(s);return n}(e,this.length-d),this,d,p);default:if(l)throw TypeError("Unknown encoding: "+s);s=(""+s).toLowerCase(),l=!0}},a.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},a.prototype.slice=function(e,t){var r=this.length;e=~~e,t=void 0===t?r:~~t,er&&(e=r),tr&&(t=r),t>>=0,t>>>=0,r||q(e,t,this.length);for(var s=this[e],n=1,i=0;++i>>=0,t>>>=0,r||q(e,t,this.length);for(var s=this[e+--t],n=1;t>0&&(n*=256);)s+=this[e+--t]*n;return s},a.prototype.readUInt8=function(e,t){return e>>>=0,t||q(e,1,this.length),this[e]},a.prototype.readUInt16LE=function(e,t){return e>>>=0,t||q(e,2,this.length),this[e]|this[e+1]>>=0,t||q(e,2,this.length),this[e]>>=0,t||q(e,4,this.length),(this[e]|this[e+1]>>=0,t||q(e,4,this.length),0x1000000*this[e]+(this[e+1]>>=0,t>>>=0,r||q(e,t,this.length);for(var s=this[e],n=1,i=0;++i=(n*=128)&&(s-=Math.pow(2,8*t)),s},a.prototype.readIntBE=function(e,t,r){e>>>=0,t>>>=0,r||q(e,t,this.length);for(var s=t,n=1,i=this[e+--s];s>0&&(n*=256);)i+=this[e+--s]*n;return i>=(n*=128)&&(i-=Math.pow(2,8*t)),i},a.prototype.readInt8=function(e,t){return(e>>>=0,t||q(e,1,this.length),128&this[e])?-((255-this[e]+1)*1):this[e]},a.prototype.readInt16LE=function(e,t){e>>>=0,t||q(e,2,this.length);var r=this[e]|this[e+1]>>=0,t||q(e,2,this.length);var r=this[e+1]|this[e]>>=0,t||q(e,4,this.length),this[e]|this[e+1]>>=0,t||q(e,4,this.length),this[e]>>=0,t||q(e,4,this.length),n.read(this,e,!0,23,4)},a.prototype.readFloatBE=function(e,t){return e>>>=0,t||q(e,4,this.length),n.read(this,e,!1,23,4)},a.prototype.readDoubleLE=function(e,t){return e>>>=0,t||q(e,8,this.length),n.read(this,e,!0,52,8)},a.prototype.readDoubleBE=function(e,t){return e>>>=0,t||q(e,8,this.length),n.read(this,e,!1,52,8)},a.prototype.writeUIntLE=function(e,t,r,s){if(e*=1,t>>>=0,r>>>=0,!s){var n=Math.pow(2,8*r)-1;w(this,e,t,r,n,0)}var i=1,o=0;for(this[t]=255&e;++o>>=0,r>>>=0,!s){var n=Math.pow(2,8*r)-1;w(this,e,t,r,n,0)}var i=r-1,o=1;for(this[t+i]=255&e;--i>=0&&(o*=256);)this[t+i]=e/o&255;return t+r},a.prototype.writeUInt8=function(e,t,r){return e*=1,t>>>=0,r||w(this,e,t,1,255,0),this[t]=255&e,t+1},a.prototype.writeUInt16LE=function(e,t,r){return e*=1,t>>>=0,r||w(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},a.prototype.writeUInt16BE=function(e,t,r){return e*=1,t>>>=0,r||w(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},a.prototype.writeUInt32LE=function(e,t,r){return e*=1,t>>>=0,r||w(this,e,t,4,0xffffffff,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},a.prototype.writeUInt32BE=function(e,t,r){return e*=1,t>>>=0,r||w(this,e,t,4,0xffffffff,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},a.prototype.writeIntLE=function(e,t,r,s){if(e*=1,t>>>=0,!s){var n=Math.pow(2,8*r-1);w(this,e,t,r,n-1,-n)}var i=0,o=1,a=0;for(this[t]=255&e;++i>>=0,!s){var n=Math.pow(2,8*r-1);w(this,e,t,r,n-1,-n)}var i=r-1,o=1,a=0;for(this[t+i]=255&e;--i>=0&&(o*=256);)e>>=0,r||w(this,e,t,1,127,-128),e>>=0,r||w(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},a.prototype.writeInt16BE=function(e,t,r){return e*=1,t>>>=0,r||w(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},a.prototype.writeInt32LE=function(e,t,r){return e*=1,t>>>=0,r||w(this,e,t,4,0x7fffffff,-0x80000000),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},a.prototype.writeInt32BE=function(e,t,r){return e*=1,t>>>=0,r||w(this,e,t,4,0x7fffffff,-0x80000000),e>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},a.prototype.writeFloatLE=function(e,t,r){return A(this,e,t,!0,r)},a.prototype.writeFloatBE=function(e,t,r){return A(this,e,t,!1,r)},a.prototype.writeDoubleLE=function(e,t,r){return T(this,e,t,!0,r)},a.prototype.writeDoubleBE=function(e,t,r){return T(this,e,t,!1,r)},a.prototype.copy=function(e,t,r,s){if(!a.isBuffer(e))throw TypeError("argument should be a Buffer");if(r||(r=0),s||0===s||(s=this.length),t>=e.length&&(t=e.length),t||(t=0),s>0&&s=this.length)throw RangeError("Index out of range");if(sthis.length&&(s=this.length),e.length-t=0;--i)e[i+t]=this[i+r];else Uint8Array.prototype.set.call(e,this.subarray(r,s),t);return n},a.prototype.fill=function(e,t,r,s){if("string"==typeof e){if("string"==typeof t?(s=t,t=0,r=this.length):"string"==typeof r&&(s=r,r=this.length),void 0!==s&&"string"!=typeof s)throw TypeError("encoding must be a string");if("string"==typeof s&&!a.isEncoding(s))throw TypeError("Unknown encoding: "+s);if(1===e.length){var n,i=e.charCodeAt(0);("utf8"===s&&i>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(n=t;n55295&&r56319||o+1===s){(t-=3)>-1&&i.push(239,191,189);continue}n=r;continue}if(r-1&&i.push(239,191,189),n=r;continue}r=(n-55296-1&&i.push(239,191,189);if(n=null,r>6|192,63&r|128)}else if(r>12|224,r>>6&63|128,63&r|128)}else if(r>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}else throw Error("Invalid code point")}return i}function E(e){for(var t=[],r=0;r=t.length)&&!(n>=e.length);++n)t[n+r]=e[n];return n}function S(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}var O=function(){for(var e="0123456789abcdef",t=Array(256),r=0;r>1,d=-7,p=r?n-1:0,c=r?-1:1,l=e[t+p];for(p+=c,i=l&(1>=-d,d+=a;d>0;i=256*i+e[t+p],p+=c,d-=8);for(o=i&(1>=-d,d+=s;d>0;o=256*o+e[t+p],p+=c,d-=8);if(0===i)i=1-h;else{if(i===u)return o?NaN:1/0*(l?-1:1);o+=Math.pow(2,s),i-=h}return(l?-1:1)*o*Math.pow(2,i-s)},t.write=function(e,t,r,s,n,i){var o,a,u,h=8*i-n-1,d=(1>1,c=5960464477539062e-23*(23===n),l=s?0:i-1,f=s?1:-1,y=+(t=1?t+=c/u:t+=c*Math.pow(2,1-p),t*u>=2&&(o++,u/=2),o+p>=d?(a=0,o=d):o+p>=1?(a=(t*u-1)*Math.pow(2,n),o+=p):(a=t*Math.pow(2,p-1)*Math.pow(2,n),o=0));n>=8;e[r+l]=255&a,l+=f,a/=256,n-=8);for(o=o0;e[r+l]=255&o,l+=f,o/=256,h-=8);e[r+l-f]|=128*y}}},n={};function i(e){var t=n[e];if(void 0!==t)return t.exports;var r=n[e]={exports:{}},o=!0;try{s[e](r,r.exports,i),o=!1}finally{o&&delete n[e]}return r.exports}i.ab="/ROOT/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected]_@[email protected]_react-d_31bb8e2462fe5ce97fc1c84d0267a791/node_modules/next/dist/compiled/buffer/",t.exports=i(72)},318631,(e,t,r)=>{"use strict";var s=e.i(217083);Object.defineProperty(r,"__esModule",{value:!0}),r.AuthAPI=void 0;let n=e.r(479252);r.AuthAPI=class{requestHandler;constructor(e){this.requestHandler=e}updateTokensFromCookies(){let e={accessToken:"access_token_from_cookies",idToken:"id_token_from_cookies",refreshToken:"refresh_token_from_cookies",expiresAt:Date.now()+36e5};this.requestHandler.setTokens(e)}async login(e){let t=await this.requestHandler.request({method:n.HttpMethod.POST,path:"/login",data:e,requiresAuth:!1});return this.updateTokensFromCookies(),t}async sendPasswordlessEmail(e){await this.requestHandler.request({method:n.HttpMethod.POST,path:"/passwordless/email",data:{email:e},requiresAuth:!1})}async loginWithPasswordlessEmail(e,t){let r=await this.requestHandler.request({method:n.HttpMethod.POST,path:"/passwordless/email/login",data:{email:e,otp:t},requiresAuth:!1});return this.updateTokensFromCookies(),r}async loginWithApple(e){let t=await this.requestHandler.request({method:n.HttpMethod.POST,path:"/sso/apple/login",data:e,requiresAuth:!1});return this.updateTokensFromCookies(),t}async loginWithGoogle(e){let t=await this.requestHandler.request({method:n.HttpMethod.POST,path:"/sso/google/login",data:e,requiresAuth:!1});return this.updateTokensFromCookies(),t}async logout(){try{await this.requestHandler.request({method:n.HttpMethod.POST,path:"/logout"})}finally{this.requestHandler.clearTokens()}}async getMachineToken(e){let t=s.Buffer.from(`${e.clientId}:${e.clientSecret}`).toString("base64"),r=await this.requestHandler.request({method:n.HttpMethod.POST,path:"/oauth/token",requiresAuth:!1,headers:{Authorization:`Basic ${t}`}}),i={accessToken:r.access_token,expiresAt:Date.now()+1e3*r.expires_in};return this.requestHandler.setTokens(i),r}async refreshToken(){let e=await this.requestHandler.request({method:n.HttpMethod.GET,path:"/refresh",requiresAuth:!1});return this.updateTokensFromCookies(),e}async register(e){return await this.requestHandler.request({method:n.HttpMethod.POST,path:"/register",data:e,requiresAuth:!1})}async registerPasswordless(e){return await this.requestHandler.request({method:n.HttpMethod.POST,path:"/passwordless/registration",data:e,requiresAuth:!1})}async verifyEmail(e,t){return await this.requestHandler.request({method:n.HttpMethod.PUT,path:"/register/verify/email",data:{email:e,otp:t},requiresAuth:!1})}async resendVerificationEmail(){await this.requestHandler.request({method:n.HttpMethod.PUT,path:"/verification/email/resend",requiresAuth:!1})}async initiateStepUpAuthViaEmail(e){await this.requestHandler.request({method:n.HttpMethod.POST,path:"/reauth/email",params:e?{platform:e}:void 0,requiresAuth:!0})}async validateStepUpAuthViaEmail(e){await this.requestHandler.request({method:n.HttpMethod.PUT,path:"/reauth/email/validation",data:{otp:e},requiresAuth:!0})}async stepUpAuthViaPassword(e,t){let r={password:e};t&&(r["g-recaptcha-response"]=t),await this.requestHandler.request({method:n.HttpMethod.PUT,path:"/reauth/password",data:r,requiresAuth:!0})}async validateStepUpAuth(){await this.requestHandler.request({method:n.HttpMethod.GET,path:"/reauth/validation",requiresAuth:!0})}async forgotPassword(e,t,r){let s={};t&&(s.reset_password_url=t),r&&(s.platform=r),await this.requestHandler.request({method:n.HttpMethod.POST,path:"/password/forgotten",data:{email:e},params:s,requiresAuth:!1})}async resetPassword(e,t,r,s){await this.requestHandler.request({method:n.HttpMethod.POST,path:"/password/reset",data:{email:e,otp:t,password:r},params:s?{platform:s}:void 0,requiresAuth:!1})}async changePassword(e,t){await this.requestHandler.request({method:n.HttpMethod.PUT,path:"/password/change",data:{old_password:e,new_password:t},requiresAuth:!0})}async changeEmail(e){await this.requestHandler.request({method:n.HttpMethod.PUT,path:"/email/change",data:{email:e},requiresAuth:!0})}async getEntitlementToken(){return await this.requestHandler.request({method:n.HttpMethod.POST,path:"/entitlement/token",requiresAuth:!0})}async getUserId(){return await this.requestHandler.request({method:n.HttpMethod.GET,path:"/user/id",requiresAuth:!0})}async getUserInfo(){return await this.requestHandler.request({method:n.HttpMethod.GET,path:"/user/id/email",requiresAuth:!0})}}},622592,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.ConsentAPI=void 0;let s=e.r(479252);r.ConsentAPI=class{requestHandler;constructor(e){this.requestHandler=e}async getConsent(e){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/consent",params:{endpointID:e}})}async updateConsent(e){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/consent",data:e})}async createConsent(e){await this.requestHandler.request({method:s.HttpMethod.POST,path:"/consent",data:e})}async deleteConsent(e){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:"/consent",params:{endpointID:e}})}async getUserConsent(){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/consent/user"})}async updateUserConsent(e){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/consent/user",data:e})}async createUserConsent(e){await this.requestHandler.request({method:s.HttpMethod.POST,path:"/consent/user",data:e})}async deleteUserConsent(){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:"/consent/user"})}async getBulkConsent(e,t){let r={};return e&&(r.endpointIDs=e),t&&(r.userID=t),this.requestHandler.request({method:s.HttpMethod.GET,path:"/consent/bulk",params:r})}async deleteBulkConsent(e,t){let r={};e&&(r.endpointIDs=e),t&&(r.userID=t),await this.requestHandler.request({method:s.HttpMethod.DELETE,path:"/consent/bulk",params:r})}async migrateUserConsent(e){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/consent/user/migration",data:e})}async updateUserConsentWebhook(e){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/consent/user/update",data:e})}}},273929,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.OpenWebAPI=void 0;let s=e.r(479252);r.OpenWebAPI=class{requestHandler;constructor(e){this.requestHandler=e}async getAccount(){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/openWeb/account",requiresAuth:!0})}async getCodeB(e){return this.requestHandler.request({method:s.HttpMethod.POST,path:"/openWeb/codeB",data:e,requiresAuth:!0})}}},63461,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.PreferenceAPI=void 0;let s=e.r(479252);r.PreferenceAPI=class{requestHandler;constructor(e){this.requestHandler=e}async getPreference(){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/preference"})}async updatePreference(e){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/preference",data:e})}async createPreference(e){await this.requestHandler.request({method:s.HttpMethod.POST,path:"/preference",data:e})}async getWUPreference(){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/preference/wu"})}async updateWUPreference(e){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/preference/wu",data:e})}async createWUPreference(e){await this.requestHandler.request({method:s.HttpMethod.POST,path:"/preference/wu",data:e})}async getUserPreference(e){return this.requestHandler.request({method:s.HttpMethod.GET,path:`/preference/${e}`})}async deleteUserPreference(e){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:`/preference/${e}`})}async createUserWUPreference(e,t){await this.requestHandler.request({method:s.HttpMethod.POST,path:`/preference/wu/${e}`,data:t})}async getMapSettings(e){return this.requestHandler.request({method:s.HttpMethod.GET,path:`/preference/map-settings/${e}`})}async createMapSettings(e,t){return this.requestHandler.request({method:s.HttpMethod.POST,path:`/preference/map-settings/${e}`,data:t})}async updateMapSettings(e,t){return this.requestHandler.request({method:s.HttpMethod.PATCH,path:`/preference/map-settings/${e}`,data:t})}async deleteMapSettings(e){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:`/preference/map-settings/${e}`})}}},339222,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.PurchaseAPI=void 0;let s=e.r(479252);r.PurchaseAPI=class{requestHandler;constructor(e){this.requestHandler=e}async getPurchases(e){let t={};return e&&(t.platform=e),this.requestHandler.request({method:s.HttpMethod.GET,path:"/purchase/",params:t})}async createPurchase(e){await this.requestHandler.request({method:s.HttpMethod.POST,path:"/purchase/app/user",data:e})}async getPurchaseRecord(e,t,r){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/purchase/record",params:{platform:e,vendor:t,product:r}})}async getPurchaseToken(e){let t={};return e&&(t.platform=e),this.requestHandler.request({method:s.HttpMethod.GET,path:"/purchase/token",params:t})}async updatePurchase(e){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/purchase",data:e})}async createPurchaseTransaction(e){await this.requestHandler.request({method:s.HttpMethod.POST,path:"/purchase",data:e})}async getUserPurchases(e){return this.requestHandler.request({method:s.HttpMethod.GET,path:`/purchase/${e}`})}async deleteUserPurchases(e){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:`/purchase/${e}`})}async getUserPurchaseSnapshot(e,t){let r={};return t&&(r.platform=t),this.requestHandler.request({method:s.HttpMethod.GET,path:`/purchase/${e}/getSnapshot`,params:r})}async getUserPurchaseRecord(e,t,r,n){return this.requestHandler.request({method:s.HttpMethod.GET,path:`/purchase/${e}/record`,params:{platform:t,vendor:r,product:n}})}}},698254,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.SegmentationAPI=void 0;let s=e.r(479252);r.SegmentationAPI=class{requestHandler;constructor(e){this.requestHandler=e}async getEndpointSegmentation(){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/segmentation/endpoint"})}async updateEndpointSegmentation(e){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/segmentation/endpoint",data:e})}async deleteEndpointSegmentation(e){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:"/segmentation/endpoint",data:{keys:e}})}async getEndpointMetrics(){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/segmentation/metrics/endpoint"})}async getUserSegmentation(){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/segmentation/user"})}async updateUserSegmentation(e){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/segmentation/user",data:e})}async deleteUserSegmentation(e){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:"/segmentation/user",data:{keys:e}})}async getUserMetrics(){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/segmentation/metrics/user"})}async getBulkSegmentation(e,t){let r={};return e&&(r.endpointIDs=e),t&&(r.userID=t),this.requestHandler.request({method:s.HttpMethod.GET,path:"/segmentation/bulk",params:r})}async deleteBulkSegmentation(e,t){let r={};e&&(r.endpointIDs=e),t&&(r.userID=t),await this.requestHandler.request({method:s.HttpMethod.DELETE,path:"/segmentation/bulk",params:r})}async updateBulkSegmentation(e){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/segmentation/analytics/bulk",data:e})}async updateKeyOnCondition(e){await this.requestHandler.request({method:s.HttpMethod.PUT,path:"/segmentation/analytics/condition",data:e})}async deleteKeyOnCondition(e){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:"/segmentation/analytics/condition",data:e})}async deleteKeyForIds(e){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:"/segmentation/analytics/key",data:e})}async deleteKeyForAll(e){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:"/segmentation/analytics/key/all",data:{key:e}})}}},168126,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.SubscriptionAPI=void 0;let s=e.r(479252);r.SubscriptionAPI=class{requestHandler;constructor(e){this.requestHandler=e}async updateActivity(e){await this.requestHandler.request({method:s.HttpMethod.PATCH,path:"/subscription/activity",data:e})}async updateAddress(e){await this.requestHandler.request({method:s.HttpMethod.PATCH,path:"/subscription/address",data:e})}async createMultiple(e){return this.requestHandler.request({method:s.HttpMethod.PUT,path:"/subscription/create",data:e})}async create(e){return this.requestHandler.request({method:s.HttpMethod.POST,path:"/subscription/create",data:e})}async delete(e){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:"/subscription/delete",params:{subids:e}})}async updateEvent(e){await this.requestHandler.request({method:s.HttpMethod.PATCH,path:"/subscription/event",data:e})}async find(e){let t={};return e.endpointId&&(t.endpointid=e.endpointId),e.address&&(t.address=e.address),e.userId&&(t.userid=e.userId),this.requestHandler.request({method:s.HttpMethod.GET,path:"/subscription/find",params:t})}async findAll(e){return this.requestHandler.request({method:s.HttpMethod.GET,path:"/subscription/findall",params:{endpoints:e}})}async updateLocation(e){await this.requestHandler.request({method:s.HttpMethod.PATCH,path:"/subscription/location",data:e})}async update(e){await this.requestHandler.request({method:s.HttpMethod.PATCH,path:"/subscription/update",data:e})}async updateAll(e){await this.requestHandler.request({method:s.HttpMethod.PATCH,path:"/subscription/updateall",data:e})}async deleteAll(e){let t={};e.endpoints&&(t.endpoints=e.endpoints),e.userId&&(t.userid=e.userId),await this.requestHandler.request({method:s.HttpMethod.DELETE,path:"/subscriptions",params:t})}}},401354,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.TripsAPI=void 0;let s=e.r(479252);r.TripsAPI=class{requestHandler;constructor(e){this.requestHandler=e}async listTrips(e){return this.requestHandler.request({method:s.HttpMethod.GET,path:`/preference/trips/${e}`})}async getTrip(e,t){return this.requestHandler.request({method:s.HttpMethod.GET,path:`/preference/trips/${e}/${t}`})}async createTrip(e,t){return this.requestHandler.request({method:s.HttpMethod.POST,path:`/preference/trips/${e}`,data:t})}async updateTrip(e,t,r){return this.requestHandler.request({method:s.HttpMethod.PUT,path:`/preference/trips/${e}/${t}`,data:r})}async deleteTrip(e,t){await this.requestHandler.request({method:s.HttpMethod.DELETE,path:`/preference/trips/${e}/${t}`})}}},391150,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.ServerError=r.RateLimitError=r.ValidationError=r.NotFoundError=r.APIError=r.UPSXError=void 0;class s extends Error{constructor(e){super(e),this.name="UPSXError",Object.setPrototypeOf(this,s.prototype)}}r.UPSXError=s;class n extends s{code;data;constructor(e,t,r){super(e),this.name="APIError",this.code=t,this.data=r,Object.setPrototypeOf(this,n.prototype)}}r.APIError=n;class i extends n{constructor(e="Resource not found"){super(e,404),this.name="NotFoundError",Object.setPrototypeOf(this,i.prototype)}}r.NotFoundError=i;class o extends n{constructor(e="Invalid request",t){super(e,400,t),this.name="ValidationError",Object.setPrototypeOf(this,o.prototype)}}r.ValidationError=o;class a extends n{constructor(e="Rate limit exceeded"){super(e,429),this.name="RateLimitError",Object.setPrototypeOf(this,a.prototype)}}r.RateLimitError=a;class u extends n{constructor(e="Server error",t=500){super(e,t),this.name="ServerError",Object.setPrototypeOf(this,u.prototype)}}r.ServerError=u},659393,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.RequestHandler=void 0;let s=e.r(391150),n=e.r(479252);r.RequestHandler=class{baseUrl;timeout;defaultHeaders;tokens=null;constructor(e){this.baseUrl=e.baseUrl.endsWith("/")?e.baseUrl.slice(0,-1):e.baseUrl,this.timeout=e.timeout||3e4,this.defaultHeaders={"Content-Type":"application/json",Accept:"application/json",...e.headers}}setTokens(e){this.tokens=e}getTokens(){return this.tokens}clearTokens(){this.tokens=null}isAuthenticated(){return!!this.tokens?.accessToken}async request(e){let{method:t,path:r,params:i,data:o,headers:a={},requiresAuth:u=!1,timeout:h=this.timeout}=e;if(u&&!this.isAuthenticated())throw new s.APIError("Authentication required");let d=`${this.baseUrl}${r.startsWith("/")?r:`/${r}`}`;if(i&&Object.keys(i).length>0){let e=new URLSearchParams;for(let[t,r]of Object.entries(i))void 0!==r&&e.append(t,String(r));let t=e.toString();t&&(d+=`?${t}`)}let p={...this.defaultHeaders,...a};this.tokens?.accessToken&&(p.Authorization=`Bearer ${this.tokens.accessToken}`);let c={method:t,headers:p,credentials:"include"};void 0!==o&&(t===n.HttpMethod.POST||t===n.HttpMethod.PUT||t===n.HttpMethod.PATCH)&&(c.body=JSON.stringify(o));try{let e=new AbortController,t=setTimeout(()=>e.abort(),h);c.signal=e.signal;let r=await fetch(d,c);if(clearTimeout(t),r.ok||await this.handleErrorResponse(r),204===r.status)return null;let s=r.headers.get("content-type");if(s&&s.includes("application/json"))return await r.json();return await r.text()}catch(e){if(e instanceof s.APIError)throw e;if(e instanceof DOMException&&"AbortError"===e.name)throw new s.APIError("Request timeout",408);throw new s.APIError(`Network error: ${e.message}`,0)}}async handleErrorResponse(e){let t;try{t=await e.json()}catch{t={message:e.statusText}}let r=t.message||"Unknown error",n=e.status;throw new s.APIError(r,n,t)}}},981444,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.UPSXClient=void 0;let s=e.r(212840),n=e.r(688029),i=e.r(750413),o=e.r(318631),a=e.r(622592),u=e.r(273929),h=e.r(63461),d=e.r(339222),p=e.r(698254),c=e.r(168126),l=e.r(401354),f=e.r(659393);r.UPSXClient=class{account;applications;assets;auth;consent;openWeb;preference;purchase;segmentation;subscription;trips;requestHandler;constructor(e){this.requestHandler=new f.RequestHandler(e),this.auth=new o.AuthAPI(this.requestHandler),this.account=new s.AccountAPI(this.requestHandler),this.applications=new n.ApplicationsAPI(this.requestHandler),this.assets=new i.AssetsAPI(this.requestHandler),this.consent=new a.ConsentAPI(this.requestHandler),this.openWeb=new u.OpenWebAPI(this.requestHandler),this.preference=new h.PreferenceAPI(this.requestHandler),this.purchase=new d.PurchaseAPI(this.requestHandler),this.segmentation=new p.SegmentationAPI(this.requestHandler),this.subscription=new c.SubscriptionAPI(this.requestHandler),this.trips=new l.TripsAPI(this.requestHandler)}}},562235,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0})},926398,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0})},534293,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0})},470429,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0})},448436,(e,t,r)=>{"use strict";var s,n,i,o,a,u,h,d,p,c,l,f,y,m,g,H,q,w,P,A,T,v,b,E,M,U,S,O,I,C,_,k;Object.defineProperty(r,"__esModule",{value:!0}),r.LocationType=r.Role=r.PermissionType=r.ActivityCondition=r.WigetPropType=r.WigetPropPeriod=r.WigetPropCondition=r.WidgetType=r.StrikeTypeCode=r.GeometryType=r.InterruptionLevel=r.Weekday=r.Platform=r.Unit=r.ActivityType=r.AlertType=void 0,(q=s||(r.AlertType=s={}))[q.News=1]="News",q[q.AirQuality=2]="AirQuality",q[q.Avalanche=3]="Avalanche",q[q.Coastal=4]="Coastal",q[q.Miscellaneous=5]="Miscellaneous",q[q.RainFlood=6]="RainFlood",q[q.Temperature=7]="Temperature",q[q.Thunderstorm=8]="Thunderstorm",q[q.Visibility=9]="Visibility",q[q.Wind=10]="Wind",q[q.Lightning=11]="Lightning",q[q.Precipitation=12]="Precipitation",q[q.ExtremeCold=13]="ExtremeCold",q[q.ExtremeHeat=14]="ExtremeHeat",q[q.WinterPrecipitation=15]="WinterPrecipitation",q[q.HeavySnow=16]="HeavySnow",q[q.DenseFog=17]="DenseFog",q[q.HeavyRain=18]="HeavyRain",q[q.HighWind=19]="HighWind",q[q.Flux=20]="Flux",q[q.IcyForecast=21]="IcyForecast",q[q.Pollen=22]="Pollen",q[q.Flu=23]="Flu",q[q.DailyPrecip=24]="DailyPrecip",q[q.WebEmail=25]="WebEmail",q[q.DailyDigest=26]="DailyDigest",q[q.HeavyThunderstorm=27]="HeavyThunderstorm",q[q.Custom=28]="Custom",q[q.Activity=29]="Activity",(w=n||(r.ActivityType=n={}))[w.Running=1]="Running",w[w.Golfing=2]="Golfing",w[w.Hiking=3]="Hiking",w[w.Gardening=4]="Gardening",w[w.Tennis=5]="Tennis",w[w.Cycling=6]="Cycling",(P=i||(r.Unit=i={}))[P.English=1]="English",P[P.Metric=2]="Metric",P[P.Hybrid=3]="Hybrid",(A=o||(r.Platform=o={}))[A.Apple=1]="Apple",A[A.Android=2]="Android",A[A.Http=3]="Http",A[A.Web=4]="Web",A[A.Email=5]="Email",A[A.Sms=6]="Sms",(T=a||(r.Weekday=a={}))[T.Sunday=0]="Sunday",T[T.Monday=1]="Monday",T[T.Tuesday=2]="Tuesday",T[T.Wednesday=3]="Wednesday",T[T.Thursday=4]="Thursday",T[T.Friday=5]="Friday",T[T.Saturday=6]="Saturday",(v=u||(r.InterruptionLevel=u={}))[v.Passive=0]="Passive",v[v.Active=1]="Active",v[v.TimeSensitive=2]="TimeSensitive",v[v.Critical=3]="Critical",(b=h||(r.GeometryType=h={})).GeometryPoint="Point",b.GeometryMultiPoint="MultiPoint",b.GeometryPolygon="Polygon",b.GeometryMultiPolygon="MultiPolygon",b.GeometryLineString="LineString",b.GeometryMultiLineString="MultiLineString",b.GeometryCollection="GeometryCollection",b.Feature="Feature",b.FeatureCollection="FeatureCollection",(E=d||(r.StrikeTypeCode=d={}))[E.CloudToGround=0]="CloudToGround",E[E.CloudToCloud=1]="CloudToCloud",(M=p||(r.WidgetType=p={})).WXLocation="wxlocation",M.WXComparison="wxcomparison",(U=c||(r.WigetPropCondition=c={})).Humidity="humidity",U.Wind="wind",U.Pressure="pressure",U.Visibility="visibility",U.DewPoint="dewPoint",U.UV="uv",U.AirQuality="airQuality",U.Temperature="temperature",U.TemperatureFeelsLike="temperatureFeelsLike",U.Precip="precip",(S=l||(r.WigetPropPeriod=l={})).Daily="daily",S.Hourly="hourly",(O=f||(r.WigetPropType=f={})).Forecast="forecast",O.Historical="historical",(I=y||(r.ActivityCondition=y={}))[I.Poor=1]="Poor",I[I.Fair=2]="Fair",I[I.Good=3]="Good",(C=m||(r.PermissionType=m={}))[C.EndpointLookup=1]="EndpointLookup",C[C.LocationLookup=2]="LocationLookup",C[C.UserLookup=3]="UserLookup",C[C.NotificationMetric=4]="NotificationMetric",C[C.ClickMetric=5]="ClickMetric",C[C.AlertMap=6]="AlertMap",C[C.AlertNews=7]="AlertNews",C[C.AlertSegment=8]="AlertSegment",C[C.NotificationApps=9]="NotificationApps",C[C.NotificationTemplates=10]="NotificationTemplates",C[C.NotificationHeadlines=11]="NotificationHeadlines",C[C.NotificationDateFormats=12]="NotificationDateFormats",C[C.NotificationTranslations=13]="NotificationTranslations",C[C.Permissions=14]="Permissions",C[C.AgentActivity=15]="AgentActivity",C[C.DeleteSubscriptions=16]="DeleteSubscriptions",C[C.AlertSent=17]="AlertSent",C[C.Culture=18]="Culture",C[C.SendNotification=19]="SendNotification",C[C.Headlines=20]="Headlines",C[C.Templates=21]="Templates",C[C.UpdateAccountLockStatus=22]="UpdateAccountLockStatus",(_=g||(r.Role=g={}))[_.Admin=1]="Admin",_[_.User=2]="User",_[_.UnAuthorized=3]="UnAuthorized",_[_.AppAgent=4]="AppAgent",(k=H||(r.LocationType=H={}))[k.Globe=0]="Globe",k[k.PollenID=1]="PollenID",k[k.TideID=2]="TideID",k[k.ZoneID=3]="ZoneID",k[k.PostalKey=4]="PostalKey",k[k.CountyID=5]="CountyID",k[k.CityID=6]="CityID",k[k.AdminDistrict=7]="AdminDistrict",k[k.DmaID=8]="DmaID",k[k.TimeZone=9]="TimeZone",k[k.CountryCode=10]="CountryCode"},1799,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0})},728575,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0})},95443,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0})},867295,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0})},832922,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0})},770367,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0})},648875,(e,t,r)=>{"use strict";var s=e.e&&e.e.__createBinding||(Object.create?function(e,t,r,s){void 0===s&&(s=r);var n=Object.getOwnPropertyDescriptor(t,r);(!n||("get"in n?!t.__esModule:n.writable||n.configurable))&&(n={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,s,n)}:function(e,t,r,s){void 0===s&&(s=r),e[s]=t[r]}),n=e.e&&e.e.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||s(t,e,r)};Object.defineProperty(r,"__esModule",{value:!0}),n(e.r(562235),r),n(e.r(926398),r),n(e.r(534293),r),n(e.r(470429),r),n(e.r(448436),r),n(e.r(1799),r),n(e.r(728575),r),n(e.r(95443),r),n(e.r(867295),r),n(e.r(832922),r),n(e.r(770367),r)},563033,(e,t,r)=>{"use strict";var s=e.e&&e.e.__createBinding||(Object.create?function(e,t,r,s){void 0===s&&(s=r);var n=Object.getOwnPropertyDescriptor(t,r);(!n||("get"in n?!t.__esModule:n.writable||n.configurable))&&(n={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,s,n)}:function(e,t,r,s){void 0===s&&(s=r),e[s]=t[r]}),n=e.e&&e.e.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||s(t,e,r)};Object.defineProperty(r,"__esModule",{value:!0}),n(e.r(212840),r),n(e.r(688029),r),n(e.r(750413),r),n(e.r(622592),r),n(e.r(273929),r),n(e.r(63461),r),n(e.r(339222),r),n(e.r(698254),r),n(e.r(168126),r),n(e.r(401354),r)},245943,(e,t,r)=>{"use strict";var s=e.e&&e.e.__createBinding||(Object.create?function(e,t,r,s){void 0===s&&(s=r);var n=Object.getOwnPropertyDescriptor(t,r);(!n||("get"in n?!t.__esModule:n.writable||n.configurable))&&(n={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,s,n)}:function(e,t,r,s){void 0===s&&(s=r),e[s]=t[r]}),n=e.e&&e.e.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||s(t,e,r)};Object.defineProperty(r,"__esModule",{value:!0}),r.APIError=r.UPSXClient=void 0;let i=e.r(981444);Object.defineProperty(r,"UPSXClient",{enumerable:!0,get:function(){return i.UPSXClient}});let o=e.r(391150);Object.defineProperty(r,"APIError",{enumerable:!0,get:function(){return o.APIError}}),n(e.r(479252),r),n(e.r(648875),r),n(e.r(563033),r)},901351,e=>{"use strict";let t=new(e.i(245943)).UPSXClient({baseUrl:"https://upsx.weather.com"});e.s(["upsxClient",0,t])},513513,e=>{"use strict";var t=e.i(543512);t.UserSubscriptionTiers.none,t.UserSubscriptionTiers.standard,t.UserSubscriptionTiers.adFree,t.UserSubscriptionTiers.premium,t.UserSubscriptionTiers.premiumWithAd,e.s(["hasRadarFeature",0,function(e){return void 0!==e&&t.UserSubscriptionPremiumTiers.includes(e)},"isUserLoggedIn",0,function(e){return void 0!==e&&e>t.UserSubscriptionTiers.none},"isUserTierPremium",0,function(e){return t.UserSubscriptionPremiumTiers.includes(e)}],513513)},528600,e=>{"use strict";var t=e.i(592121),r=e.i(546446),s=e.i(949920),n=e.i(646341),i=e.i(889753),o=e.i(901351),a=e.i(310847),u=e.i(543512),h=e.i(990033),d=e.i(333350),p=e.i(513513);e.s(["useUser",0,function(){let[e,c]=(0,r.useAtom)(i.userProfileAtom),[l,f]=(0,r.useAtom)(a.wxuUserAnonymousIdAtom),[y,m]=(0,r.useAtom)(a.wxuUserAccountUserAccountResponseAtom),[g,H]=(0,t.useState)(!1),q=(0,r.useSetAtom)(a.wxuLoginRedirectPageAtom);d.default&&!g&&(q(window.location.href),H(!0));let w=(0,r.useAtomValue)(i.userTierAtom),P=(0,p.isUserLoggedIn)(w),A=(0,n.getCookie)("ANON_C"),T=A||l||(0,h.v4)();A||(0,n.setCookie)("ANON_C",T,{path:"/",domain:".weather.com",secure:!0}),(!l||l&&A&&l!==A)&&f(T),!e&&y&&c(y);let v=(0,s.default)(P?"upsx/id":null,()=>o.upsxClient.account.getAccountId(),{shouldRetryOnError:e=>"APIError"!==e.name}),{userID:b=""}=v?.data||{},E=b&&e?.userID!==b;return(0,s.default)(E?"upsx/account":null,()=>o.upsxClient.account.getAccount(),{shouldRetryOnError:e=>"APIError"!==e.name,onSuccess:e=>{c(e),m(e)}}),{user:{anonId:l,userID:b,isUserLoggedIn:P,subscriptionTier:w,isUserPremium:(0,p.isUserTierPremium)(w),isUserAdFree:w===u.UserSubscriptionTiers.adFree},userProfile:e,isUserIdLoading:v.isLoading}}])}]);