hyperstack-react 0.6.4 → 0.6.5

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.
package/dist/index.js CHANGED
@@ -6978,7 +6978,9 @@ class ConnectionManager {
6978
6978
  if (this.authConfig?.tokenEndpoint) {
6979
6979
  return this.authConfig.tokenEndpoint;
6980
6980
  }
6981
- if (this.hostedHyperstackUrl && this.authConfig?.publishableKey) {
6981
+ // Always use the default hosted token endpoint for hosted URLs,
6982
+ // even without a publishableKey - some endpoints don't require auth
6983
+ if (this.hostedHyperstackUrl) {
6982
6984
  return DEFAULT_HOSTED_TOKEN_ENDPOINT;
6983
6985
  }
6984
6986
  return undefined;
@@ -7022,9 +7024,6 @@ class ConnectionManager {
7022
7024
  return this.currentToken;
7023
7025
  }
7024
7026
  const strategy = this.getAuthStrategy();
7025
- if (strategy.kind === 'none' && this.hostedHyperstackUrl) {
7026
- throw new HyperStackError('Hosted Hyperstack websocket connections require auth.publishableKey, auth.getToken, auth.tokenEndpoint, or auth.token', 'AUTH_REQUIRED');
7027
- }
7028
7027
  switch (strategy.kind) {
7029
7028
  case 'static-token':
7030
7029
  return this.updateTokenState(strategy.token);