(error: unknown)
| 381 | }; |
| 382 | |
| 383 | const isProxyAuthError = (error: unknown): boolean => { |
| 384 | return ( |
| 385 | error instanceof Error && |
| 386 | error.message.includes("Authentication required. Use the session token") |
| 387 | ); |
| 388 | }; |
| 389 | |
| 390 | const handleAuthError = async (error: unknown) => { |
| 391 | if (isConnectionAuthError(error)) { |