try{let e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},r=(new e.Error).stack;r&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[r]="21bcef85-e4ea-4668-aaf4-091496004955",e._sentryDebugIdIdentifier="sentry-dbid-21bcef85-e4ea-4668-aaf4-091496004955")}catch(e){}{let e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{};e._sentryModuleMetadata=e._sentryModuleMetadata||{},e._sentryModuleMetadata[new e.Error().stack]=Object.assign({},e._sentryModuleMetadata[new e.Error().stack],{"_sentryBundlerPluginAppKey:anthropic-apps":!0})}(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[78947],{0x1ee873af:(e,r,t)=>{"use strict";t.d(r,{Q:()=>s,t:()=>i});var o=t(0x9845e38c),n=t(0x16ab3413b),l=t.n(n),a=t(0xfc89b4a4);function i(e){var r,t,n;let{key:i,defaultValue:s,deserialize:u=JSON.parse,getInitialValueInEffect:d=!1,sync:c=!0}=e,f="LSS-".concat(i),g=(0,a.useRef)(null!=(n=null==(r=(t=crypto).randomUUID)?void 0:r.call(t))?n:"".concat(Date.now(),"-").concat(Math.random().toString(36).slice(2))),b=(0,a.useRef)(!1),[p,v]=(0,a.useState)(()=>{if(d)return s;try{let e=window.localStorage.getItem(f);if(e){let r=JSON.parse(e);if(r&&"object"==typeof r&&"value"in r)return r.value;return u(e)}}catch(e){o.v.warn(o.u.LOCAL_STORAGE,"Error reading localStorage key “".concat(f,"”"),e)}return s});(0,a.useEffect)(()=>{if(d)try{let e=window.localStorage.getItem(f);if(e){let r=JSON.parse(e);r&&"object"==typeof r&&"value"in r?v(r.value):v(u(e))}}catch(e){o.v.warn(o.u.LOCAL_STORAGE,"Error reading localStorage key “".concat(f,"”"),e)}},[f,u,d]);let y=(0,a.useCallback)(e=>{b.current=!0,v(r=>{let t="function"==typeof e?e(r):e;try{let e={value:t,tabId:g.current,timestamp:Date.now()},r=JSON.stringify(e);if(window.localStorage.setItem(f,r),c){let e=new StorageEvent("storage",{key:f,newValue:r,oldValue:window.localStorage.getItem(f),storageArea:window.localStorage,url:window.location.href});setTimeout(()=>{window.dispatchEvent(e)},0)}}catch(e){o.v.warn(o.u.LOCAL_STORAGE,"Error writing localStorage key “".concat(f,"”"),e)}return t}),Promise.resolve().then(()=>{b.current=!1})},[f,c]),h=(0,a.useCallback)(()=>{window.localStorage.removeItem(f),v(s)},[f,s]);return(0,a.useEffect)(()=>{if(!c)return;let e=e=>{if(e.key===f&&e.newValue&&!b.current)try{let r=JSON.parse(e.newValue);if(r&&"object"==typeof r&&"value"in r&&"tabId"in r){if(r.tabId===g.current)return;v(e=>l()(e,r.value)?e:r.value)}else{let r=u(e.newValue);v(e=>l()(e,r)?e:r)}}catch(e){o.v.warn(o.u.LOCAL_STORAGE,"Error handling storage event for “".concat(f,"”"),e)}};return window.addEventListener("storage",e),()=>window.removeEventListener("storage",e)},[f,c,u]),[p,y,h]}function s(e,r){let t=!(arguments.length>2)||void 0===arguments[2]||arguments[2];return i({key:e,defaultValue:r,deserialize:e=>void 0===e?r:JSON.parse(e),getInitialValueInEffect:!1,sync:t})}},0x495c605f:(e,r,t)=>{"use strict";t.d(r,{Ah:()=>a,Bs:()=>n,NJ:()=>l,VH:()=>o,Xs:()=>s,u5:()=>i});let o=e=>{let{account:r,isClaudeDot:t}=e;return t?!1===r.settings.has_finished_claudeai_onboarding:!r.full_name||!r.display_name},n=(e,r)=>r&&!e.is_verified,l=(e,r)=>!!function(e,r){for(let t of e.invites)if(t.organization.capabilities&&t.organization.capabilities.includes(r))return t}(e,r?"raven":"api"),a=(e,r)=>!r&&0===e.invites.length&&0===e.memberships.filter(e=>e.organization.capabilities.includes("api")).length,i=function(e,r){let t=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return t&&r&&!e.age_is_verified},s=function(e,r){let t=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return o({account:e,isClaudeDot:r})||n(e,r)||l(e,r)||a(e,r)||i(e,r,t)}},0x865ff458:(e,r,t)=>{"use strict";t.d(r,{EL:()=>h,Hc:()=>b,XK:()=>p,Zl:()=>y,hz:()=>g,y_:()=>v});var o=t(0x12c9046cd),n=t(0x24553dffe),l=t(0x139b5e710),a=t(0x20e00cddd),i=t(0x49fac030),s=t(0xac309a83),u=t(0xfc89b4a4),d=t(0x1ab0d1ca1),c=t(0x156c4e43b),f=t(0x19572a4ef);function g(){var e;let r=(0,n.l)(),t=null!=(e=r.get(a.eT.PROMOTION))?e:null;return{data:(0,f.lx)(t),mutate:(0,u.useCallback)(e=>{r.set(a.eT.PROMOTION,JSON.stringify(e),{maxAgeSeconds:7776e3})},[r]),delete:(0,u.useCallback)(()=>{r.set(a.eT.PROMOTION,"",{maxAgeSeconds:0})},[r])}}function b(){var e,r,t;let{data:n}=g(),l=(r=null!=(e=null==n?void 0:n.promotionId)?e:null,t=e=>(0,f.IQ)(e,n),(0,o.Sk)("/api/billing/promotion/".concat(r),{queryKey:[i.t6,r],enabled:!!r,meta:{noToast:!0}},e=>(e.promotionId=r,t)?t(e):e));return{...l,isPending:l.isPending&&!!(null==n?void 0:n.promotionId)}}function p(){let{data:e,mutate:r}=g();(0,u.useEffect)(()=>{(null==e?void 0:e.needsCheckout)&&(e.needsCheckout=void 0,r(e))},[e,r])}function v(e){let{data:r,mutate:t}=g(),o=null==r?void 0:r.promotionId,n=(0,s.T9)("claude_ai_targeted_promotion","promotionId",null,c.Yj().nullable());return(0,u.useEffect)(()=>{!o&&n&&t({promotionId:n})},[o,n,t]),!!e&&!!(null==r?void 0:r.needsCheckout)&&!!(null==r?void 0:r.promotionId)}let y=()=>{let e=(0,u.useRef)(!1),r=(0,l.Yf)(),t=(0,d.A)(),{delete:o}=g();return(0,u.useCallback)(n=>{(null==n?void 0:n.offerError)&&!e.current&&(e.current=!0,r.addError(t.formatMessage({defaultMessage:"This promotion is not available for your account",id:"Vu9kt6ezVH"}),{error:Error(n.offerError),messageForLogging:"This promotion is not available for your account"}),o())},[r,o,t])},h=()=>{let e=(0,u.useRef)(!1),r=(0,l.Yf)(),t=(0,d.A)(),{delete:o}=g();return(0,u.useCallback)(n=>{(null==n?void 0:n.source)==="referral_code"&&(null==n?void 0:n.error)&&!e.current&&(e.current=!0,r.addError(t.formatMessage({defaultMessage:"This referral code is no longer valid",id:"Bsr7TrjB5Q"}),{error:Error(n.error),messageForLogging:"This referral code is no longer valid"}),o())},[r,o,t])}},0x9f369389:(e,r,t)=>{"use strict";var o,n,l,a,i,s,u,d,c,f,g,b,p,v,y,h,m,w,x,_,E,T,S,k,C;t.d(r,{CI:()=>K,EC:()=>D,EG:()=>J,Fd:()=>A,Nj:()=>z,Q2:()=>P,Un:()=>H,VW:()=>G,Vx:()=>j,Xo:()=>W,dw:()=>Y,f$:()=>I,fv:()=>U,gD:()=>O,gI:()=>F,lT:()=>N,m_:()=>M,s0:()=>B,uV:()=>L,wk:()=>Q,y7:()=>V,y8:()=>R}),t(0xc6b3c857),null==(o=globalThis["claude.web"])||o.WindowControl;let M=null==(n=globalThis["claude.web"])?void 0:n.QuickEntry,I=null==(l=globalThis["claude.web"])?void 0:l.LocalSessions,A=null==(a=globalThis["claude.web"])?void 0:a.LocalAgentModeSessions,L=null==(i=globalThis["claude.web"])?void 0:i.AgentModeFeedback,O=null==(s=globalThis["claude.web"])?void 0:s.Account,j=null==(u=globalThis["claude.web"])?void 0:u.Navigation,N=null==(d=globalThis["claude.web"])?void 0:d.DeepLink,V=null==(c=globalThis["claude.web"])?void 0:c.WindowState,R=null==(f=globalThis["claude.web"])?void 0:f.Toast,P=null==(g=globalThis["claude.web"])?void 0:g.FileSystem;null==(b=globalThis["claude.web"])||b.OpenDocuments;let z=null==(p=globalThis["claude.web"])?void 0:p.Auth,D=null==(v=globalThis["claude.web"])?void 0:v.Resources,F=null==(y=globalThis["claude.web"])?void 0:y.ClaudeCode,J=null==(h=globalThis["claude.web"])?void 0:h.ClaudeVM,G=null==(m=globalThis["claude.web"])?void 0:m.LocalSessionEnvironment,Y=null==(w=globalThis["claude.web"])?void 0:w.DesktopNotifications,K=null==(x=globalThis["claude.web"])?void 0:x.LocalPlugins,W=null==(_=globalThis["claude.web"])?void 0:_.AutoUpdater,Q=null==(E=globalThis["claude.web"])?void 0:E.LocalKBs,B=null==(T=globalThis["claude.web"])?void 0:T.CustomPlugins;null==(S=globalThis["claude.web"])||S.Launch;let U=null==(k=globalThis["claude.web"])?void 0:k.BrowserNavigation,H=null==(C=globalThis["claude.web"])?void 0:C.ChromeExtension},0xb804d868:(e,r,t)=>{"use strict";t.d(r,{Vc:()=>a,Wz:()=>l});var o=t(0x11bc810a7),n=t(0x1ee873af);function l(e,r){return(0,o.F)({key:"SSS-".concat(e),defaultValue:r,serialize:JSON.stringify,deserialize:e=>void 0===e?r:JSON.parse(e)})}function a(e,r){let t=!(arguments.length>2)||void 0===arguments[2]||arguments[2];return(0,n.Q)(e,r,t)}},0xc6b3c857:(e,r,t)=>{"use strict";t.d(r,{FI:()=>a,J8:()=>n,_Y:()=>o,t4:()=>l});var o=function(e){return e.VSCode="vscode",e.Cursor="cursor",e.Zed="zed",e}({}),n=function(e){return e.NotInstalled="not_installed",e.Updating="updating",e.Ready="ready",e}({}),l=function(e){return e.Idle="idle",e.Checking="checking",e.Downloading="downloading",e.Ready="ready",e.Error="error",e}({}),a=function(e){return e.Succeeded="succeeded",e.Skipped="skipped",e.Error="error",e}({})},0x139b5e710:(e,r,t)=>{"use strict";t.d(r,{ErrorSegmentConnector:()=>R,ErrorsProvider:()=>O,MS:()=>I,ic:()=>P,Yf:()=>j});var o=t(0x22102fd88),n=t(0x495c605f),l=t(0x1016c6ed2);t(0x9845e38c);var a=t(0xac309a83),i=t(0x253a5c787),s=t(0x8009b83c),u=t.n(s),d=t(0x1d22aa00b),c=t.n(d),f=t(0x1351529bf),g=t.n(f),b=t(0x4d348f95),p=t(0xfc89b4a4),v=t(0x38e6572),y=t(0x156c4e43b),h=t(0xf32c56dd),m=t(0x14de19ae8);t(0x7dbd6363);function w(e,r){let t=[];for(let o of e){if(null==o)continue;let e=x(o,r+1);""!==e&&t.push(e)}return t.length>0?t.join(" "):""}function x(e){let r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return r>5?"":e instanceof Error?e.message:"string"==typeof e||"number"==typeof e||"boolean"==typeof e?String(e):p.isValidElement(e)?function e(r,t){var o;let n=r.props;if("object"==typeof n&&null!==n&&"defaultMessage"in n&&"string"==typeof n.defaultMessage)return n.defaultMessage;if("function"==typeof r.type&&"object"==typeof r.props&&null!==r.props)try{let e=(0,r.type)(r.props);if(e)return x(e,t+1)}catch(e){}return"object"==typeof n&&null!==n&&"children"in n?(o=n.children,"string"==typeof o||"number"==typeof o||"boolean"==typeof o?String(o):null==o?"":Array.isArray(o)?w(o,t+1):p.isValidElement(o)?e(o,t+1):x(o,t+1)):""}(e,r):Array.isArray(e)?w(e,r):""}let _=e=>{if(e instanceof Error){if("statusCode"in e&&"number"==typeof e.statusCode)return e.statusCode;if("status"in e&&"number"==typeof e.status)return e.status}},E=e=>{var r;if(e instanceof l.LG&&(null==(r=e.extra)?void 0:r.details)&&"object"==typeof e.extra.details&&"error_visibility"in e.extra.details)return String(e.extra.details.error_visibility)},T=e=>e instanceof l.LG?e.type:e instanceof Error?e.name:typeof e,S=e=>{if(e instanceof l.LG){var r;if(e.errorCode)return e.errorCode;if((null==(r=e.extra)?void 0:r.details)&&"object"==typeof e.extra.details&&"error_code"in e.extra.details&&"string"==typeof e.extra.details.error_code)return e.extra.details.error_code}if(e instanceof Error&&"code"in e)return String(e.code)};var k=t(0xb804d868);let C=null,M=null;function I(e){C=e.onError,M=e.onSegmentReady}let A=(0,p.createContext)(void 0);function L(e){var r;let{userFacingMessage:t,error:o,toastId:n,errorContext:a,track:i,isApiError:s}=e;null==C||C();let u=x(t);i({event_key:"claudeai.user_facing_error.shown",error_message:u?"".concat(u.substring(0,200)).concat(u.length>200?"...":""):"[Error message could not be extracted for logging]",toast_id:n,error_type:T(o),error_source:(null==a||null==(r=a.tags)?void 0:r.source)||"unknown",error_endpoint:o instanceof l.LG?o.endpoint:void 0,error_method:o instanceof l.LG?o.method:void 0,has_original_error:!!o,original_error_message:o instanceof Error?o.message.substring(0,200):void 0,error_stack_trace:(e=>{if(e instanceof Error&&e.stack)return e.stack.split("\n").slice(0,3).join("\n").substring(0,500)})(o),error_code:S(o),error_status_code:_(o),error_visibility:E(o),websocket_close_code:(e=>{var r;if(e instanceof l.LG&&(null==(r=e.extra)?void 0:r.details)&&"object"==typeof e.extra.details&&"websocket_close_code"in e.extra.details&&"number"==typeof e.extra.details.websocket_close_code)return e.extra.details.websocket_close_code})(o),is_instanceof_api_error:o instanceof l.LG,is_caller_api_error:s,offline_status:"undefined"!=typeof navigator?!navigator.onLine:void 0})}function O(e){let{children:r}=e,t=(0,p.useRef)(1),[n,l]=(0,p.useState)([]),a=(0,p.useRef)(null),s=(0,p.useRef)([]),u=(0,p.useCallback)(e=>{a.current=e,s.current.forEach(r=>{e(r,void 0)}),s.current=[],null==M||M(e)},[]),d=(0,p.useCallback)(async e=>{if(null!==a.current)return a.current(e);s.current.push(e)},[]),c=(0,p.useCallback)(e=>{l(r=>r.filter(r=>r.id!==e))},[]),f=(0,p.useCallback)((e,r)=>{let o=t.current++,{timeout:n,error:a,errorContext:i,messageForLogging:s,uniqueKey:u}=r||{};return L({userFacingMessage:s||e,error:a,toastId:o,errorContext:i,track:d,isApiError:!1}),l(r=>[...r,{id:o,message:e,toastType:"error",uniqueKey:u,details:""}]),n&&setTimeout(()=>c(o),n),o},[c,"",d]),g=(0,p.useCallback)((e,r)=>{let n=t.current++,{timeout:a,errorContext:s}=r||{},u=e instanceof Error?e.message:String(e);if("user_facing"!==E(e))if(500===_(e))u=(0,o.jsx)(v.A,{defaultMessage:"This isn't working right now. You can try again later.",id:"+jfKVKRlw7"});else{null==C||C(),e instanceof TypeError&&(e.message.startsWith("Failed to fetch")||e.message.startsWith("NetworkError when attempting to fetch resource.")||e.message.startsWith("Load failed"))||(0,i.Cp)(e,{tags:{source:"api-error"},extra:{isSuppressed:!0}});return}return"account_needs_verification"===u&&(u="Your account needs to be verified."),L({userFacingMessage:u,error:e,toastId:n,errorContext:s,track:d,isApiError:!0}),l(e=>[...e,{id:n,message:u,toastType:"error",details:""}]),a&&setTimeout(()=>c(n),a),n},[c,"",d]),b=(0,p.useCallback)((e,r)=>{let o=t.current++,{timeout:n,uniqueKey:a}=r||{};return l(r=>[...r,{id:o,message:e,toastType:"info",uniqueKey:a}]),n&&setTimeout(()=>c(o),n),o},[c]),y=(0,p.useMemo)(()=>({toasts:n,addError:f,addApiError:g,addSuccess:b,clearToast:c,registerSegmentTracker:u}),[n,f,g,b,c,u]);return(0,o.jsx)(A.Provider,{value:y,children:r})}function j(){let e=(0,p.useContext)(A);if(!e)throw Error("Must be called within ErrorsProvider");return e}let N=y.Ik({id:y.Yj().optional().nullable(),title:y.Yj().optional().nullable(),message:y.Yj().optional().nullable(),displayFrequencyHours:y.ai().optional().nullable()}),V={};function R(){let{registerSegmentTracker:e}=j(),{track:r}=(0,h.st)();return(0,p.useEffect)(()=>{e(r)},[e,r]),null}function P(){var e;let{id:r,title:t,message:o,displayFrequencyHours:l}=(0,a.iW)("claude_system_message",V,N),{account:i}=(0,m.YL)(),s=null!=(e=null==i?void 0:i.uuid)?e:"logged-out",d=(0,b.usePathname)(),[f,v]=(0,k.Vc)("dismissed-system-messages",{}),y=(0,p.useMemo)(()=>()=>v(e=>{let t=u()(e);return r&&g()(t,[s,r],Date.now()),t}),[v,s,r]);return(0,p.useMemo)(()=>{if(!i||(0,n.Xs)(i,!0)||"/download"===d||!r)return!1;let e=c()(f,[s,r]);return!e||"boolean"==typeof e||!!l&&Date.now()-e>=60*l*6e4},[i,r,s,f,l,d])?{currentSystemMessageId:r,currentSystemMessageTitle:t,currentSystemMessageContent:o,dismissCurrentSystemMessage:y}:{currentSystemMessageId:null,currentSystemMessageTitle:null,currentSystemMessageContent:null,dismissCurrentSystemMessage:()=>null}}},0x19572a4ef:(e,r,t)=>{"use strict";t.d(r,{IQ:()=>l,Jd:()=>o,lx:()=>n});let o=["proMonthlyPromoCode","proAnnualPromoCode","welcomeMessageTitle","utmParams","max5xMonthlyPromoCode","max20xMonthlyPromoCode"],n=e=>{if(!e)return null;try{return JSON.parse(e)}catch(e){return null}},l=(e,r)=>(null==r?void 0:r.overrides)?{...e,...r.overrides}:e},0x1b5efc8c2:(e,r,t)=>{Promise.resolve().then(t.bind(t,0x1ecc17c21))},0x1ecc17c21:(e,r,t)=>{"use strict";t.r(r),t.d(r,{default:()=>s});var o=t(0x22102fd88),n=t(0x1f16c1247),l=t(0x253a5c787),a=t(0xfc89b4a4),i=t(0x38e6572);function s(e){let{error:r,reset:t}=e;return(0,a.useEffect)(()=>{(0,l.Cp)(r)},[r]),(0,o.jsxs)("section",{className:"grid min-h-screen gap-2",children:[(0,o.jsx)("h2",{children:(0,o.jsx)(i.A,{defaultMessage:"Error",id:"KN7zKn8z4F"})}),(0,o.jsx)("p",{children:r.message}),(0,o.jsx)(n.Nr,{onClick:()=>t(),children:(0,o.jsx)(i.A,{defaultMessage:"Try again",id:"FazwRldA7z"})})]})}}},e=>{e.O(0,[59624,95977,13263,37633,59666,2574,19664,44145,59597,85948,53396,64939,73417,93949,18113,80559,94882,20330,45312,10489,38869,67077,64328,74813,83907,61440,53675,13877,72647,587,92351,77358],()=>e(e.s=0x1b5efc8c2)),_N_E=e.O()}]);