@thestatic-tv/dcl-sdk 2.6.0 → 2.6.1

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.d.mts CHANGED
@@ -1196,6 +1196,14 @@ declare class StaticTVClient {
1196
1196
  * @internal
1197
1197
  */
1198
1198
  private _resolveFeaturesReady;
1199
+ /**
1200
+ * Called by SessionModule when the session could not start - the server
1201
+ * refused it (an unpaid legacy key, since 2026-10-07) or the request failed.
1202
+ * With no tier ever confirmed that is the free tier: onFeaturesReady() must
1203
+ * settle, never hang a scene awaiting it. A tier already confirmed stays.
1204
+ * @internal
1205
+ */
1206
+ _settleFeaturesAsFree(): void;
1199
1207
  /**
1200
1208
  * Called by SessionModule when server returns the tier
1201
1209
  * Enables modules based on tier level
package/dist/index.d.ts CHANGED
@@ -1196,6 +1196,14 @@ declare class StaticTVClient {
1196
1196
  * @internal
1197
1197
  */
1198
1198
  private _resolveFeaturesReady;
1199
+ /**
1200
+ * Called by SessionModule when the session could not start - the server
1201
+ * refused it (an unpaid legacy key, since 2026-10-07) or the request failed.
1202
+ * With no tier ever confirmed that is the free tier: onFeaturesReady() must
1203
+ * settle, never hang a scene awaiting it. A tier already confirmed stays.
1204
+ * @internal
1205
+ */
1206
+ _settleFeaturesAsFree(): void;
1199
1207
  /**
1200
1208
  * Called by SessionModule when server returns the tier
1201
1209
  * Enables modules based on tier level
package/dist/index.js CHANGED
@@ -485,9 +485,11 @@ var SessionModule = class {
485
485
  this.client._enableFeaturesForTier(this._tier, this._keyId);
486
486
  return this.sessionId;
487
487
  }
488
+ this.client._settleFeaturesAsFree();
488
489
  return null;
489
490
  } catch (error) {
490
491
  this.client.log(`Failed to start session: ${error}`);
492
+ this.client._settleFeaturesAsFree();
491
493
  return null;
492
494
  }
493
495
  }
@@ -3986,11 +3988,6 @@ var StaticTVClient = class {
3986
3988
  return;
3987
3989
  }
3988
3990
  this.session = new SessionModule(this);
3989
- if (this._keyType === KEY_TYPE_CHANNEL) {
3990
- this._tier = "standard";
3991
- this._initStandardModules();
3992
- this._resolveFeaturesReady("standard");
3993
- }
3994
3991
  if (this.config.autoStartSession) {
3995
3992
  fetchUserData().then(() => {
3996
3993
  this.session.startSession().catch((err) => {
@@ -4490,6 +4487,19 @@ var StaticTVClient = class {
4490
4487
  this._featuresReadyResolve(tier);
4491
4488
  }
4492
4489
  }
4490
+ /**
4491
+ * Called by SessionModule when the session could not start - the server
4492
+ * refused it (an unpaid legacy key, since 2026-10-07) or the request failed.
4493
+ * With no tier ever confirmed that is the free tier: onFeaturesReady() must
4494
+ * settle, never hang a scene awaiting it. A tier already confirmed stays.
4495
+ * @internal
4496
+ */
4497
+ _settleFeaturesAsFree() {
4498
+ if (!this._featuresResolved) {
4499
+ this._tier = "free";
4500
+ this._resolveFeaturesReady("free");
4501
+ }
4502
+ }
4493
4503
  /**
4494
4504
  * Called by SessionModule when server returns the tier
4495
4505
  * Enables modules based on tier level
package/dist/index.mjs CHANGED
@@ -437,9 +437,11 @@ var SessionModule = class {
437
437
  this.client._enableFeaturesForTier(this._tier, this._keyId);
438
438
  return this.sessionId;
439
439
  }
440
+ this.client._settleFeaturesAsFree();
440
441
  return null;
441
442
  } catch (error) {
442
443
  this.client.log(`Failed to start session: ${error}`);
444
+ this.client._settleFeaturesAsFree();
443
445
  return null;
444
446
  }
445
447
  }
@@ -3938,11 +3940,6 @@ var StaticTVClient = class {
3938
3940
  return;
3939
3941
  }
3940
3942
  this.session = new SessionModule(this);
3941
- if (this._keyType === KEY_TYPE_CHANNEL) {
3942
- this._tier = "standard";
3943
- this._initStandardModules();
3944
- this._resolveFeaturesReady("standard");
3945
- }
3946
3943
  if (this.config.autoStartSession) {
3947
3944
  fetchUserData().then(() => {
3948
3945
  this.session.startSession().catch((err) => {
@@ -4442,6 +4439,19 @@ var StaticTVClient = class {
4442
4439
  this._featuresReadyResolve(tier);
4443
4440
  }
4444
4441
  }
4442
+ /**
4443
+ * Called by SessionModule when the session could not start - the server
4444
+ * refused it (an unpaid legacy key, since 2026-10-07) or the request failed.
4445
+ * With no tier ever confirmed that is the free tier: onFeaturesReady() must
4446
+ * settle, never hang a scene awaiting it. A tier already confirmed stays.
4447
+ * @internal
4448
+ */
4449
+ _settleFeaturesAsFree() {
4450
+ if (!this._featuresResolved) {
4451
+ this._tier = "free";
4452
+ this._resolveFeaturesReady("free");
4453
+ }
4454
+ }
4445
4455
  /**
4446
4456
  * Called by SessionModule when server returns the tier
4447
4457
  * Enables modules based on tier level
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thestatic-tv/dcl-sdk",
3
- "version": "2.6.0",
3
+ "version": "2.6.1",
4
4
  "description": "Connect your Decentraland scene to thestatic.tv - full channel lineup, metrics tracking, and interactions",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",