@experteam-mx/ngx-services 20.8.8 → 20.8.9
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/index.d.ts
CHANGED
|
@@ -9424,6 +9424,8 @@ declare class WebSocketsService {
|
|
|
9424
9424
|
private appKey;
|
|
9425
9425
|
private connectPromise;
|
|
9426
9426
|
private environments;
|
|
9427
|
+
private getAuthToken;
|
|
9428
|
+
private readonly channelAuthHeaders;
|
|
9427
9429
|
/**
|
|
9428
9430
|
* Stores the Pusher/Soketi application key without opening a connection.
|
|
9429
9431
|
* The first `channelSub` / `eventBind` opens Pusher via `ensureConnected`.
|
|
@@ -9431,6 +9433,13 @@ declare class WebSocketsService {
|
|
|
9431
9433
|
* @param {string} appKey - The Pusher/Soketi application key.
|
|
9432
9434
|
*/
|
|
9433
9435
|
setAppKey(appKey: string): void;
|
|
9436
|
+
/**
|
|
9437
|
+
* Registers a live token provider used when authorizing private/presence channels.
|
|
9438
|
+
* The provider is called at subscribe/authorize time; the token is not snapshotted here.
|
|
9439
|
+
*
|
|
9440
|
+
* @param {() => string | null} getToken - Returns the current session token, or null.
|
|
9441
|
+
*/
|
|
9442
|
+
setAuthTokenProvider(getToken: () => string | null): void;
|
|
9434
9443
|
/**
|
|
9435
9444
|
* Connects to Pusher using the given app key and env `sockets` url/port/debug.
|
|
9436
9445
|
* No-ops if already connected with the same key; reconnects if the key changed.
|
|
@@ -9478,6 +9487,7 @@ declare class WebSocketsService {
|
|
|
9478
9487
|
*/
|
|
9479
9488
|
eventUnbind<T>(channel: Channel, event: string): Observable<unknown>;
|
|
9480
9489
|
private ensureConnected;
|
|
9490
|
+
private refreshChannelAuthHeader;
|
|
9481
9491
|
private wait;
|
|
9482
9492
|
static ɵfac: i0.ɵɵFactoryDeclaration<WebSocketsService, never>;
|
|
9483
9493
|
static ɵprov: i0.ɵɵInjectableDeclaration<WebSocketsService>;
|