@urun-sh/core 0.6.16 → 0.6.18

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.
@@ -1,2 +1,2 @@
1
1
  import { createRequire as __urunCreateRequire } from 'node:module'; const require = globalThis.require ?? __urunCreateRequire(import.meta.url);
2
- import"../chunk-NLAOQUYQ.mjs";var p="serve";function d(n,o){let e=`[urun/${o.adapter}]`,r=n.baseUrl!==void 0||n.orgId!==void 0||n.app!==void 0||n.functionName!==void 0;if(n.session&&r)throw new Error(`${e} pass EITHER a \`session\` (BYO) OR connection settings (\`baseUrl\`/\`orgId\`/\`app\`) \u2014 not both.`);let u,c=()=>{if(n.session){let s=n.session;return Promise.resolve(typeof s=="function"?s():s)}let{baseUrl:i,orgId:t,app:a}=n;if(!i||!t||!a)throw new Error(`${e} missing connection settings: \`baseUrl\`, \`orgId\` and \`app\` are required (or pass a \`session\`).`);return l({...n,baseUrl:i,orgId:t,app:a})};return()=>u??=c()}async function l(n){let{App:o}=await import("../app-JQES6MVY.mjs"),e=o(n.app,{baseUrl:n.baseUrl,orgId:n.orgId,jwt:n.jwt,getAccessToken:n.getAccessToken,authProvider:n.authProvider}),r=n.functionName??p;return e[r]()}export{d as createSessionResolver};
2
+ import"../chunk-NLAOQUYQ.mjs";var p="serve";function d(n,o){let e=`[urun/${o.adapter}]`,r=n.baseUrl!==void 0||n.orgId!==void 0||n.app!==void 0||n.functionName!==void 0;if(n.session&&r)throw new Error(`${e} pass EITHER a \`session\` (BYO) OR connection settings (\`baseUrl\`/\`orgId\`/\`app\`) \u2014 not both.`);let u,c=()=>{if(n.session){let s=n.session;return Promise.resolve(typeof s=="function"?s():s)}let{baseUrl:i,orgId:t,app:a}=n;if(!i||!t||!a)throw new Error(`${e} missing connection settings: \`baseUrl\`, \`orgId\` and \`app\` are required (or pass a \`session\`).`);return l({...n,baseUrl:i,orgId:t,app:a})};return()=>u??=c()}async function l(n){let{App:o}=await import("../app-7M5NBLQS.mjs"),e=o(n.app,{baseUrl:n.baseUrl,orgId:n.orgId,jwt:n.jwt,getAccessToken:n.getAccessToken,authProvider:n.authProvider}),r=n.functionName??p;return e[r]()}export{d as createSessionResolver};
@@ -1,2 +1,2 @@
1
1
  import { createRequire as __urunCreateRequire } from 'node:module'; const require = globalThis.require ?? __urunCreateRequire(import.meta.url);
2
- import{ea as a,fa as b}from"./chunk-GEHV47FN.mjs";import"./chunk-6NLEURUP.mjs";import"./chunk-NLAOQUYQ.mjs";export{b as App,a as sessionDirectory};
2
+ import{ea as a,fa as b}from"./chunk-D65T46UC.mjs";import"./chunk-THU4G74G.mjs";import"./chunk-NLAOQUYQ.mjs";export{b as App,a as sessionDirectory};
@@ -848,6 +848,8 @@ interface SessionDirectoryRequestOptions {
848
848
  getAccessToken?: AllocateSessionOptions['getAccessToken'];
849
849
  authProvider?: string;
850
850
  }
851
+
852
+ type SessionNameSource = 'user' | 'auto';
851
853
  interface PrewakeOptions {
852
854
  baseUrl: string;
853
855
 
@@ -1787,4 +1789,14 @@ interface DataChannelTransport {
1787
1789
 
1788
1790
  declare function transportStreamData(transport: DataChannelTransport): StreamDataTransport;
1789
1791
 
1790
- export { type ReleaseSessionBeaconOptions as $, type AccessTokenOptions$1 as A, type GenerationTick as B, type ChannelEndpoint as C, DERIVED_LEG_SEP as D, type MediaChunkSource as E, type MediaChunkSourceFactory as F, GENERATION_TICK_EMIT_INTERVAL_MS as G, type MediaRecorderChunkSourceOptions as H, type InboundStatsSample as I, type MediaSession as J, type NegotiatorOptions as K, LoopbackStreamData as L, type MediaChunkBinding as M, type NegotiatorDataLaneSeam as N, type PathLiveness as O, type PathHealthReporting as P, type Presence as Q, type PresenceState as R, type PrewakeOptions as S, type PrewakeResult as T, type PrewakeStatus as U, type QuicStreamDataTransport as V, type Recording as W, type RecordingBucket as X, type RecordingLifecycle as Y, type RecordingStatus as Z, type RecordingsAccessor as _, type AccessTokenOptions as a, encodeStreamEnvelope as a$, type RequestOptions as a0, type RequestStreamOptions as a1, type RuntimeArtifact as a2, type RuntimeArtifactDownload as a3, type RuntimeArtifactsAccessor as a4, type RuntimeAvailability as a5, type RuntimeWakeDetail as a6, type RuntimeWakeGolden as a7, type RuntimeWakeReasonCode as a8, SIGNALING_PROTOCOL_VERSION as a9, type TransportOfferRequest as aA, type TransportOfferResponse as aB, TransportSession as aC, type TransportSessionOptions as aD, TransportSessionSignaling as aE, type TransportState as aF, type VideoPlayoutOptions as aG, WT_CONTROL_FRAME_MAX as aH, WT_DATA_STREAM_VERSION as aI, type WatchGenerationTickOptions as aJ, type WtAudioLaneSeam as aK, type WtAudioUplinkSeam as aL, WtControlDecoder as aM, type WtControlMessage as aN, type WtDataEnvelope as aO, type WtDataLaneSink as aP, WtDataStreamParser as aQ, WtDataUplinkSender as aR, type WtVideoUplinkSeam as aS, allocateSession as aT, consumeWtDataStreams as aU, createPresence as aV, createWebsocketDocConnector as aW, decodeStreamEnvelope as aX, deriveYjsServerUrl as aY, derivedLegName as aZ, derivedLegRole as a_, STREAM_END as aa, type Session as ab, type SessionDiagnostic as ac, type SessionDirectoryRequestOptions as ad, type SessionDocument as ae, SessionDocumentImpl as af, type SessionEndResult as ag, type SessionFailureKind as ah, type SessionPhase as ai, type SessionPhaseError as aj, type SessionPhaseName as ak, type SessionStartOptions as al, type SessionStatsOptions as am, type SessionStatsSample as an, type SessionStatus as ao, type SessionStream as ap, type SessionText as aq, type SignalCarrier as ar, type Signaling as as, type StartSessionOptions as at, type Store as au, type StoreOptions as av, type StreamChunkOptions as aw, type StreamDataTransport as ax, type TransportEstablishedNotify as ay, TransportNegotiator as az, type ActivationEvent as b, encodeWtControlFrame as b0, isPendingRecording as b1, mediaRecorderChunkSource as b2, parseDgramHeader as b3, prewake as b4, releaseSessionBeacon as b5, streamDataLabel as b6, transportStreamData as b7, watchGenerationTick as b8, writeDgramHeader as b9, type ActivationState as c, type ActivitySignalMode as d, type AllocateSessionOptions as e, type AllocatedSession as f, type App as g, type AppOptions as h, type AttachOptions as i, type AudioPlayoutOptions as j, type ChannelMessage as k, ChannelMultiplexer as l, type ChannelName as m, type ChunkReadable as n, DGRAM_HEADER_BYTES as o, DOC_SYNC_WIRE_CONTRACT_VERSION as p, DeferredChannelMultiplexer as q, DeferredDocConnector as r, type DerivedLegRole as s, type DgramHeader as t, type DocConnection as u, type DocConnectionState as v, type DocConnector as w, type DocServerUrlResolver as x, type DocTokenSupplier as y, GENERATION_TICK_MAX_EXTRAPOLATION_MS as z };
1792
+ declare const BACKOFF_BASE_MS = 500;
1793
+
1794
+ declare const BACKOFF_MAX_MS = 15000;
1795
+
1796
+ declare const BACKOFF_MAX_ATTEMPTS = 6;
1797
+
1798
+ declare function computeBackoffDelay(attempt: number, random?: () => number): number;
1799
+
1800
+ declare function isRetryableSessionError(error: unknown): boolean;
1801
+
1802
+ export { type RecordingLifecycle as $, type AccessTokenOptions as A, BACKOFF_BASE_MS as B, type ChannelEndpoint as C, DERIVED_LEG_SEP as D, type DocTokenSupplier as E, GENERATION_TICK_MAX_EXTRAPOLATION_MS as F, GENERATION_TICK_EMIT_INTERVAL_MS as G, type GenerationTick as H, type InboundStatsSample as I, type MediaChunkSource as J, type MediaChunkSourceFactory as K, LoopbackStreamData as L, type MediaChunkBinding as M, type MediaRecorderChunkSourceOptions as N, type MediaSession as O, type NegotiatorDataLaneSeam as P, type NegotiatorOptions as Q, type PathHealthReporting as R, type PathLiveness as S, type Presence as T, type PresenceState as U, type PrewakeOptions as V, type PrewakeResult as W, type PrewakeStatus as X, type QuicStreamDataTransport as Y, type Recording as Z, type RecordingBucket as _, type AccessTokenOptions$1 as a, createWebsocketDocConnector as a$, type RecordingStatus as a0, type RecordingsAccessor as a1, type ReleaseSessionBeaconOptions as a2, type RequestOptions as a3, type RequestStreamOptions as a4, type RuntimeArtifact as a5, type RuntimeArtifactDownload as a6, type RuntimeArtifactsAccessor as a7, type RuntimeAvailability as a8, type RuntimeWakeDetail as a9, type StreamChunkOptions as aA, type StreamDataTransport as aB, type TransportEstablishedNotify as aC, TransportNegotiator as aD, type TransportOfferRequest as aE, type TransportOfferResponse as aF, TransportSession as aG, type TransportSessionOptions as aH, TransportSessionSignaling as aI, type TransportState as aJ, type VideoPlayoutOptions as aK, WT_CONTROL_FRAME_MAX as aL, WT_DATA_STREAM_VERSION as aM, type WatchGenerationTickOptions as aN, type WtAudioLaneSeam as aO, type WtAudioUplinkSeam as aP, WtControlDecoder as aQ, type WtControlMessage as aR, type WtDataEnvelope as aS, type WtDataLaneSink as aT, WtDataStreamParser as aU, WtDataUplinkSender as aV, type WtVideoUplinkSeam as aW, allocateSession as aX, computeBackoffDelay as aY, consumeWtDataStreams as aZ, createPresence as a_, type RuntimeWakeGolden as aa, type RuntimeWakeReasonCode as ab, SIGNALING_PROTOCOL_VERSION as ac, STREAM_END as ad, type Session as ae, type SessionDiagnostic as af, type SessionDirectoryRequestOptions as ag, type SessionDocument as ah, SessionDocumentImpl as ai, type SessionEndResult as aj, type SessionFailureKind as ak, type SessionNameSource as al, type SessionPhase as am, type SessionPhaseError as an, type SessionPhaseName as ao, type SessionStartOptions as ap, type SessionStatsOptions as aq, type SessionStatsSample as ar, type SessionStatus as as, type SessionStream as at, type SessionText as au, type SignalCarrier as av, type Signaling as aw, type StartSessionOptions as ax, type Store as ay, type StoreOptions as az, type ActivationEvent as b, decodeStreamEnvelope as b0, deriveYjsServerUrl as b1, derivedLegName as b2, derivedLegRole as b3, encodeStreamEnvelope as b4, encodeWtControlFrame as b5, isPendingRecording as b6, isRetryableSessionError as b7, mediaRecorderChunkSource as b8, parseDgramHeader as b9, prewake as ba, releaseSessionBeacon as bb, streamDataLabel as bc, transportStreamData as bd, watchGenerationTick as be, writeDgramHeader as bf, type ActivationState as c, type ActivitySignalMode as d, type AllocateSessionOptions as e, type AllocatedSession as f, type App as g, type AppOptions as h, type AttachOptions as i, type AudioPlayoutOptions as j, BACKOFF_MAX_ATTEMPTS as k, BACKOFF_MAX_MS as l, type ChannelMessage as m, ChannelMultiplexer as n, type ChannelName as o, type ChunkReadable as p, DGRAM_HEADER_BYTES as q, DOC_SYNC_WIRE_CONTRACT_VERSION as r, DeferredChannelMultiplexer as s, DeferredDocConnector as t, type DerivedLegRole as u, type DgramHeader as v, type DocConnection as w, type DocConnectionState as x, type DocConnector as y, type DocServerUrlResolver as z };
@@ -848,6 +848,8 @@ interface SessionDirectoryRequestOptions {
848
848
  getAccessToken?: AllocateSessionOptions['getAccessToken'];
849
849
  authProvider?: string;
850
850
  }
851
+
852
+ type SessionNameSource = 'user' | 'auto';
851
853
  interface PrewakeOptions {
852
854
  baseUrl: string;
853
855
 
@@ -1787,4 +1789,14 @@ interface DataChannelTransport {
1787
1789
 
1788
1790
  declare function transportStreamData(transport: DataChannelTransport): StreamDataTransport;
1789
1791
 
1790
- export { type ReleaseSessionBeaconOptions as $, type AccessTokenOptions$1 as A, type GenerationTick as B, type ChannelEndpoint as C, DERIVED_LEG_SEP as D, type MediaChunkSource as E, type MediaChunkSourceFactory as F, GENERATION_TICK_EMIT_INTERVAL_MS as G, type MediaRecorderChunkSourceOptions as H, type InboundStatsSample as I, type MediaSession as J, type NegotiatorOptions as K, LoopbackStreamData as L, type MediaChunkBinding as M, type NegotiatorDataLaneSeam as N, type PathLiveness as O, type PathHealthReporting as P, type Presence as Q, type PresenceState as R, type PrewakeOptions as S, type PrewakeResult as T, type PrewakeStatus as U, type QuicStreamDataTransport as V, type Recording as W, type RecordingBucket as X, type RecordingLifecycle as Y, type RecordingStatus as Z, type RecordingsAccessor as _, type AccessTokenOptions as a, encodeStreamEnvelope as a$, type RequestOptions as a0, type RequestStreamOptions as a1, type RuntimeArtifact as a2, type RuntimeArtifactDownload as a3, type RuntimeArtifactsAccessor as a4, type RuntimeAvailability as a5, type RuntimeWakeDetail as a6, type RuntimeWakeGolden as a7, type RuntimeWakeReasonCode as a8, SIGNALING_PROTOCOL_VERSION as a9, type TransportOfferRequest as aA, type TransportOfferResponse as aB, TransportSession as aC, type TransportSessionOptions as aD, TransportSessionSignaling as aE, type TransportState as aF, type VideoPlayoutOptions as aG, WT_CONTROL_FRAME_MAX as aH, WT_DATA_STREAM_VERSION as aI, type WatchGenerationTickOptions as aJ, type WtAudioLaneSeam as aK, type WtAudioUplinkSeam as aL, WtControlDecoder as aM, type WtControlMessage as aN, type WtDataEnvelope as aO, type WtDataLaneSink as aP, WtDataStreamParser as aQ, WtDataUplinkSender as aR, type WtVideoUplinkSeam as aS, allocateSession as aT, consumeWtDataStreams as aU, createPresence as aV, createWebsocketDocConnector as aW, decodeStreamEnvelope as aX, deriveYjsServerUrl as aY, derivedLegName as aZ, derivedLegRole as a_, STREAM_END as aa, type Session as ab, type SessionDiagnostic as ac, type SessionDirectoryRequestOptions as ad, type SessionDocument as ae, SessionDocumentImpl as af, type SessionEndResult as ag, type SessionFailureKind as ah, type SessionPhase as ai, type SessionPhaseError as aj, type SessionPhaseName as ak, type SessionStartOptions as al, type SessionStatsOptions as am, type SessionStatsSample as an, type SessionStatus as ao, type SessionStream as ap, type SessionText as aq, type SignalCarrier as ar, type Signaling as as, type StartSessionOptions as at, type Store as au, type StoreOptions as av, type StreamChunkOptions as aw, type StreamDataTransport as ax, type TransportEstablishedNotify as ay, TransportNegotiator as az, type ActivationEvent as b, encodeWtControlFrame as b0, isPendingRecording as b1, mediaRecorderChunkSource as b2, parseDgramHeader as b3, prewake as b4, releaseSessionBeacon as b5, streamDataLabel as b6, transportStreamData as b7, watchGenerationTick as b8, writeDgramHeader as b9, type ActivationState as c, type ActivitySignalMode as d, type AllocateSessionOptions as e, type AllocatedSession as f, type App as g, type AppOptions as h, type AttachOptions as i, type AudioPlayoutOptions as j, type ChannelMessage as k, ChannelMultiplexer as l, type ChannelName as m, type ChunkReadable as n, DGRAM_HEADER_BYTES as o, DOC_SYNC_WIRE_CONTRACT_VERSION as p, DeferredChannelMultiplexer as q, DeferredDocConnector as r, type DerivedLegRole as s, type DgramHeader as t, type DocConnection as u, type DocConnectionState as v, type DocConnector as w, type DocServerUrlResolver as x, type DocTokenSupplier as y, GENERATION_TICK_MAX_EXTRAPOLATION_MS as z };
1792
+ declare const BACKOFF_BASE_MS = 500;
1793
+
1794
+ declare const BACKOFF_MAX_MS = 15000;
1795
+
1796
+ declare const BACKOFF_MAX_ATTEMPTS = 6;
1797
+
1798
+ declare function computeBackoffDelay(attempt: number, random?: () => number): number;
1799
+
1800
+ declare function isRetryableSessionError(error: unknown): boolean;
1801
+
1802
+ export { type RecordingLifecycle as $, type AccessTokenOptions as A, BACKOFF_BASE_MS as B, type ChannelEndpoint as C, DERIVED_LEG_SEP as D, type DocTokenSupplier as E, GENERATION_TICK_MAX_EXTRAPOLATION_MS as F, GENERATION_TICK_EMIT_INTERVAL_MS as G, type GenerationTick as H, type InboundStatsSample as I, type MediaChunkSource as J, type MediaChunkSourceFactory as K, LoopbackStreamData as L, type MediaChunkBinding as M, type MediaRecorderChunkSourceOptions as N, type MediaSession as O, type NegotiatorDataLaneSeam as P, type NegotiatorOptions as Q, type PathHealthReporting as R, type PathLiveness as S, type Presence as T, type PresenceState as U, type PrewakeOptions as V, type PrewakeResult as W, type PrewakeStatus as X, type QuicStreamDataTransport as Y, type Recording as Z, type RecordingBucket as _, type AccessTokenOptions$1 as a, createWebsocketDocConnector as a$, type RecordingStatus as a0, type RecordingsAccessor as a1, type ReleaseSessionBeaconOptions as a2, type RequestOptions as a3, type RequestStreamOptions as a4, type RuntimeArtifact as a5, type RuntimeArtifactDownload as a6, type RuntimeArtifactsAccessor as a7, type RuntimeAvailability as a8, type RuntimeWakeDetail as a9, type StreamChunkOptions as aA, type StreamDataTransport as aB, type TransportEstablishedNotify as aC, TransportNegotiator as aD, type TransportOfferRequest as aE, type TransportOfferResponse as aF, TransportSession as aG, type TransportSessionOptions as aH, TransportSessionSignaling as aI, type TransportState as aJ, type VideoPlayoutOptions as aK, WT_CONTROL_FRAME_MAX as aL, WT_DATA_STREAM_VERSION as aM, type WatchGenerationTickOptions as aN, type WtAudioLaneSeam as aO, type WtAudioUplinkSeam as aP, WtControlDecoder as aQ, type WtControlMessage as aR, type WtDataEnvelope as aS, type WtDataLaneSink as aT, WtDataStreamParser as aU, WtDataUplinkSender as aV, type WtVideoUplinkSeam as aW, allocateSession as aX, computeBackoffDelay as aY, consumeWtDataStreams as aZ, createPresence as a_, type RuntimeWakeGolden as aa, type RuntimeWakeReasonCode as ab, SIGNALING_PROTOCOL_VERSION as ac, STREAM_END as ad, type Session as ae, type SessionDiagnostic as af, type SessionDirectoryRequestOptions as ag, type SessionDocument as ah, SessionDocumentImpl as ai, type SessionEndResult as aj, type SessionFailureKind as ak, type SessionNameSource as al, type SessionPhase as am, type SessionPhaseError as an, type SessionPhaseName as ao, type SessionStartOptions as ap, type SessionStatsOptions as aq, type SessionStatsSample as ar, type SessionStatus as as, type SessionStream as at, type SessionText as au, type SignalCarrier as av, type Signaling as aw, type StartSessionOptions as ax, type Store as ay, type StoreOptions as az, type ActivationEvent as b, decodeStreamEnvelope as b0, deriveYjsServerUrl as b1, derivedLegName as b2, derivedLegRole as b3, encodeStreamEnvelope as b4, encodeWtControlFrame as b5, isPendingRecording as b6, isRetryableSessionError as b7, mediaRecorderChunkSource as b8, parseDgramHeader as b9, prewake as ba, releaseSessionBeacon as bb, streamDataLabel as bc, transportStreamData as bd, watchGenerationTick as be, writeDgramHeader as bf, type ActivationState as c, type ActivitySignalMode as d, type AllocateSessionOptions as e, type AllocatedSession as f, type App as g, type AppOptions as h, type AttachOptions as i, type AudioPlayoutOptions as j, BACKOFF_MAX_ATTEMPTS as k, BACKOFF_MAX_MS as l, type ChannelMessage as m, ChannelMultiplexer as n, type ChannelName as o, type ChunkReadable as p, DGRAM_HEADER_BYTES as q, DOC_SYNC_WIRE_CONTRACT_VERSION as r, DeferredChannelMultiplexer as s, DeferredDocConnector as t, type DerivedLegRole as u, type DgramHeader as v, type DocConnection as w, type DocConnectionState as x, type DocConnector as y, type DocServerUrlResolver as z };
@@ -848,6 +848,8 @@ interface SessionDirectoryRequestOptions {
848
848
  getAccessToken?: AllocateSessionOptions['getAccessToken'];
849
849
  authProvider?: string;
850
850
  }
851
+
852
+ type SessionNameSource = 'user' | 'auto';
851
853
  interface PrewakeOptions {
852
854
  baseUrl: string;
853
855
 
@@ -1787,4 +1789,14 @@ interface DataChannelTransport {
1787
1789
 
1788
1790
  declare function transportStreamData(transport: DataChannelTransport): StreamDataTransport;
1789
1791
 
1790
- export { type ReleaseSessionBeaconOptions as $, type AccessTokenOptions as A, type GenerationTick as B, type ChannelEndpoint as C, DERIVED_LEG_SEP as D, type MediaChunkSource as E, type MediaChunkSourceFactory as F, GENERATION_TICK_EMIT_INTERVAL_MS as G, type MediaRecorderChunkSourceOptions as H, type InboundStatsSample as I, type MediaSession as J, type NegotiatorOptions as K, LoopbackStreamData as L, type MediaChunkBinding as M, type NegotiatorDataLaneSeam as N, type PathLiveness as O, type PathHealthReporting as P, type Presence as Q, type PresenceState as R, type PrewakeOptions as S, type PrewakeResult as T, type PrewakeStatus as U, type QuicStreamDataTransport as V, type Recording as W, type RecordingBucket as X, type RecordingLifecycle as Y, type RecordingStatus as Z, type RecordingsAccessor as _, type AccessTokenOptions$1 as a, encodeStreamEnvelope as a$, type RequestOptions as a0, type RequestStreamOptions as a1, type RuntimeArtifact as a2, type RuntimeArtifactDownload as a3, type RuntimeArtifactsAccessor as a4, type RuntimeAvailability as a5, type RuntimeWakeDetail as a6, type RuntimeWakeGolden as a7, type RuntimeWakeReasonCode as a8, SIGNALING_PROTOCOL_VERSION as a9, type TransportOfferRequest as aA, type TransportOfferResponse as aB, TransportSession as aC, type TransportSessionOptions as aD, TransportSessionSignaling as aE, type TransportState as aF, type VideoPlayoutOptions as aG, WT_CONTROL_FRAME_MAX as aH, WT_DATA_STREAM_VERSION as aI, type WatchGenerationTickOptions as aJ, type WtAudioLaneSeam as aK, type WtAudioUplinkSeam as aL, WtControlDecoder as aM, type WtControlMessage as aN, type WtDataEnvelope as aO, type WtDataLaneSink as aP, WtDataStreamParser as aQ, WtDataUplinkSender as aR, type WtVideoUplinkSeam as aS, allocateSession as aT, consumeWtDataStreams as aU, createPresence as aV, createWebsocketDocConnector as aW, decodeStreamEnvelope as aX, deriveYjsServerUrl as aY, derivedLegName as aZ, derivedLegRole as a_, STREAM_END as aa, type Session as ab, type SessionDiagnostic as ac, type SessionDirectoryRequestOptions as ad, type SessionDocument as ae, SessionDocumentImpl as af, type SessionEndResult as ag, type SessionFailureKind as ah, type SessionPhase as ai, type SessionPhaseError as aj, type SessionPhaseName as ak, type SessionStartOptions as al, type SessionStatsOptions as am, type SessionStatsSample as an, type SessionStatus as ao, type SessionStream as ap, type SessionText as aq, type SignalCarrier as ar, type Signaling as as, type StartSessionOptions as at, type Store as au, type StoreOptions as av, type StreamChunkOptions as aw, type StreamDataTransport as ax, type TransportEstablishedNotify as ay, TransportNegotiator as az, type ActivationEvent as b, encodeWtControlFrame as b0, isPendingRecording as b1, mediaRecorderChunkSource as b2, parseDgramHeader as b3, prewake as b4, releaseSessionBeacon as b5, streamDataLabel as b6, transportStreamData as b7, watchGenerationTick as b8, writeDgramHeader as b9, type ActivationState as c, type ActivitySignalMode as d, type AllocateSessionOptions as e, type AllocatedSession as f, type App as g, type AppOptions as h, type AttachOptions as i, type AudioPlayoutOptions as j, type ChannelMessage as k, ChannelMultiplexer as l, type ChannelName as m, type ChunkReadable as n, DGRAM_HEADER_BYTES as o, DOC_SYNC_WIRE_CONTRACT_VERSION as p, DeferredChannelMultiplexer as q, DeferredDocConnector as r, type DerivedLegRole as s, type DgramHeader as t, type DocConnection as u, type DocConnectionState as v, type DocConnector as w, type DocServerUrlResolver as x, type DocTokenSupplier as y, GENERATION_TICK_MAX_EXTRAPOLATION_MS as z };
1792
+ declare const BACKOFF_BASE_MS = 500;
1793
+
1794
+ declare const BACKOFF_MAX_MS = 15000;
1795
+
1796
+ declare const BACKOFF_MAX_ATTEMPTS = 6;
1797
+
1798
+ declare function computeBackoffDelay(attempt: number, random?: () => number): number;
1799
+
1800
+ declare function isRetryableSessionError(error: unknown): boolean;
1801
+
1802
+ export { type RecordingLifecycle as $, type AccessTokenOptions$1 as A, BACKOFF_BASE_MS as B, type ChannelEndpoint as C, DERIVED_LEG_SEP as D, type DocTokenSupplier as E, GENERATION_TICK_MAX_EXTRAPOLATION_MS as F, GENERATION_TICK_EMIT_INTERVAL_MS as G, type GenerationTick as H, type InboundStatsSample as I, type MediaChunkSource as J, type MediaChunkSourceFactory as K, LoopbackStreamData as L, type MediaChunkBinding as M, type MediaRecorderChunkSourceOptions as N, type MediaSession as O, type NegotiatorDataLaneSeam as P, type NegotiatorOptions as Q, type PathHealthReporting as R, type PathLiveness as S, type Presence as T, type PresenceState as U, type PrewakeOptions as V, type PrewakeResult as W, type PrewakeStatus as X, type QuicStreamDataTransport as Y, type Recording as Z, type RecordingBucket as _, type AccessTokenOptions as a, createWebsocketDocConnector as a$, type RecordingStatus as a0, type RecordingsAccessor as a1, type ReleaseSessionBeaconOptions as a2, type RequestOptions as a3, type RequestStreamOptions as a4, type RuntimeArtifact as a5, type RuntimeArtifactDownload as a6, type RuntimeArtifactsAccessor as a7, type RuntimeAvailability as a8, type RuntimeWakeDetail as a9, type StreamChunkOptions as aA, type StreamDataTransport as aB, type TransportEstablishedNotify as aC, TransportNegotiator as aD, type TransportOfferRequest as aE, type TransportOfferResponse as aF, TransportSession as aG, type TransportSessionOptions as aH, TransportSessionSignaling as aI, type TransportState as aJ, type VideoPlayoutOptions as aK, WT_CONTROL_FRAME_MAX as aL, WT_DATA_STREAM_VERSION as aM, type WatchGenerationTickOptions as aN, type WtAudioLaneSeam as aO, type WtAudioUplinkSeam as aP, WtControlDecoder as aQ, type WtControlMessage as aR, type WtDataEnvelope as aS, type WtDataLaneSink as aT, WtDataStreamParser as aU, WtDataUplinkSender as aV, type WtVideoUplinkSeam as aW, allocateSession as aX, computeBackoffDelay as aY, consumeWtDataStreams as aZ, createPresence as a_, type RuntimeWakeGolden as aa, type RuntimeWakeReasonCode as ab, SIGNALING_PROTOCOL_VERSION as ac, STREAM_END as ad, type Session as ae, type SessionDiagnostic as af, type SessionDirectoryRequestOptions as ag, type SessionDocument as ah, SessionDocumentImpl as ai, type SessionEndResult as aj, type SessionFailureKind as ak, type SessionNameSource as al, type SessionPhase as am, type SessionPhaseError as an, type SessionPhaseName as ao, type SessionStartOptions as ap, type SessionStatsOptions as aq, type SessionStatsSample as ar, type SessionStatus as as, type SessionStream as at, type SessionText as au, type SignalCarrier as av, type Signaling as aw, type StartSessionOptions as ax, type Store as ay, type StoreOptions as az, type ActivationEvent as b, decodeStreamEnvelope as b0, deriveYjsServerUrl as b1, derivedLegName as b2, derivedLegRole as b3, encodeStreamEnvelope as b4, encodeWtControlFrame as b5, isPendingRecording as b6, isRetryableSessionError as b7, mediaRecorderChunkSource as b8, parseDgramHeader as b9, prewake as ba, releaseSessionBeacon as bb, streamDataLabel as bc, transportStreamData as bd, watchGenerationTick as be, writeDgramHeader as bf, type ActivationState as c, type ActivitySignalMode as d, type AllocateSessionOptions as e, type AllocatedSession as f, type App as g, type AppOptions as h, type AttachOptions as i, type AudioPlayoutOptions as j, BACKOFF_MAX_ATTEMPTS as k, BACKOFF_MAX_MS as l, type ChannelMessage as m, ChannelMultiplexer as n, type ChannelName as o, type ChunkReadable as p, DGRAM_HEADER_BYTES as q, DOC_SYNC_WIRE_CONTRACT_VERSION as r, DeferredChannelMultiplexer as s, DeferredDocConnector as t, type DerivedLegRole as u, type DgramHeader as v, type DocConnection as w, type DocConnectionState as x, type DocConnector as y, type DocServerUrlResolver as z };
@@ -848,6 +848,8 @@ interface SessionDirectoryRequestOptions {
848
848
  getAccessToken?: AllocateSessionOptions['getAccessToken'];
849
849
  authProvider?: string;
850
850
  }
851
+
852
+ type SessionNameSource = 'user' | 'auto';
851
853
  interface PrewakeOptions {
852
854
  baseUrl: string;
853
855
 
@@ -1787,4 +1789,14 @@ interface DataChannelTransport {
1787
1789
 
1788
1790
  declare function transportStreamData(transport: DataChannelTransport): StreamDataTransport;
1789
1791
 
1790
- export { type ReleaseSessionBeaconOptions as $, type AccessTokenOptions as A, type GenerationTick as B, type ChannelEndpoint as C, DERIVED_LEG_SEP as D, type MediaChunkSource as E, type MediaChunkSourceFactory as F, GENERATION_TICK_EMIT_INTERVAL_MS as G, type MediaRecorderChunkSourceOptions as H, type InboundStatsSample as I, type MediaSession as J, type NegotiatorOptions as K, LoopbackStreamData as L, type MediaChunkBinding as M, type NegotiatorDataLaneSeam as N, type PathLiveness as O, type PathHealthReporting as P, type Presence as Q, type PresenceState as R, type PrewakeOptions as S, type PrewakeResult as T, type PrewakeStatus as U, type QuicStreamDataTransport as V, type Recording as W, type RecordingBucket as X, type RecordingLifecycle as Y, type RecordingStatus as Z, type RecordingsAccessor as _, type AccessTokenOptions$1 as a, encodeStreamEnvelope as a$, type RequestOptions as a0, type RequestStreamOptions as a1, type RuntimeArtifact as a2, type RuntimeArtifactDownload as a3, type RuntimeArtifactsAccessor as a4, type RuntimeAvailability as a5, type RuntimeWakeDetail as a6, type RuntimeWakeGolden as a7, type RuntimeWakeReasonCode as a8, SIGNALING_PROTOCOL_VERSION as a9, type TransportOfferRequest as aA, type TransportOfferResponse as aB, TransportSession as aC, type TransportSessionOptions as aD, TransportSessionSignaling as aE, type TransportState as aF, type VideoPlayoutOptions as aG, WT_CONTROL_FRAME_MAX as aH, WT_DATA_STREAM_VERSION as aI, type WatchGenerationTickOptions as aJ, type WtAudioLaneSeam as aK, type WtAudioUplinkSeam as aL, WtControlDecoder as aM, type WtControlMessage as aN, type WtDataEnvelope as aO, type WtDataLaneSink as aP, WtDataStreamParser as aQ, WtDataUplinkSender as aR, type WtVideoUplinkSeam as aS, allocateSession as aT, consumeWtDataStreams as aU, createPresence as aV, createWebsocketDocConnector as aW, decodeStreamEnvelope as aX, deriveYjsServerUrl as aY, derivedLegName as aZ, derivedLegRole as a_, STREAM_END as aa, type Session as ab, type SessionDiagnostic as ac, type SessionDirectoryRequestOptions as ad, type SessionDocument as ae, SessionDocumentImpl as af, type SessionEndResult as ag, type SessionFailureKind as ah, type SessionPhase as ai, type SessionPhaseError as aj, type SessionPhaseName as ak, type SessionStartOptions as al, type SessionStatsOptions as am, type SessionStatsSample as an, type SessionStatus as ao, type SessionStream as ap, type SessionText as aq, type SignalCarrier as ar, type Signaling as as, type StartSessionOptions as at, type Store as au, type StoreOptions as av, type StreamChunkOptions as aw, type StreamDataTransport as ax, type TransportEstablishedNotify as ay, TransportNegotiator as az, type ActivationEvent as b, encodeWtControlFrame as b0, isPendingRecording as b1, mediaRecorderChunkSource as b2, parseDgramHeader as b3, prewake as b4, releaseSessionBeacon as b5, streamDataLabel as b6, transportStreamData as b7, watchGenerationTick as b8, writeDgramHeader as b9, type ActivationState as c, type ActivitySignalMode as d, type AllocateSessionOptions as e, type AllocatedSession as f, type App as g, type AppOptions as h, type AttachOptions as i, type AudioPlayoutOptions as j, type ChannelMessage as k, ChannelMultiplexer as l, type ChannelName as m, type ChunkReadable as n, DGRAM_HEADER_BYTES as o, DOC_SYNC_WIRE_CONTRACT_VERSION as p, DeferredChannelMultiplexer as q, DeferredDocConnector as r, type DerivedLegRole as s, type DgramHeader as t, type DocConnection as u, type DocConnectionState as v, type DocConnector as w, type DocServerUrlResolver as x, type DocTokenSupplier as y, GENERATION_TICK_MAX_EXTRAPOLATION_MS as z };
1792
+ declare const BACKOFF_BASE_MS = 500;
1793
+
1794
+ declare const BACKOFF_MAX_MS = 15000;
1795
+
1796
+ declare const BACKOFF_MAX_ATTEMPTS = 6;
1797
+
1798
+ declare function computeBackoffDelay(attempt: number, random?: () => number): number;
1799
+
1800
+ declare function isRetryableSessionError(error: unknown): boolean;
1801
+
1802
+ export { type RecordingLifecycle as $, type AccessTokenOptions$1 as A, BACKOFF_BASE_MS as B, type ChannelEndpoint as C, DERIVED_LEG_SEP as D, type DocTokenSupplier as E, GENERATION_TICK_MAX_EXTRAPOLATION_MS as F, GENERATION_TICK_EMIT_INTERVAL_MS as G, type GenerationTick as H, type InboundStatsSample as I, type MediaChunkSource as J, type MediaChunkSourceFactory as K, LoopbackStreamData as L, type MediaChunkBinding as M, type MediaRecorderChunkSourceOptions as N, type MediaSession as O, type NegotiatorDataLaneSeam as P, type NegotiatorOptions as Q, type PathHealthReporting as R, type PathLiveness as S, type Presence as T, type PresenceState as U, type PrewakeOptions as V, type PrewakeResult as W, type PrewakeStatus as X, type QuicStreamDataTransport as Y, type Recording as Z, type RecordingBucket as _, type AccessTokenOptions as a, createWebsocketDocConnector as a$, type RecordingStatus as a0, type RecordingsAccessor as a1, type ReleaseSessionBeaconOptions as a2, type RequestOptions as a3, type RequestStreamOptions as a4, type RuntimeArtifact as a5, type RuntimeArtifactDownload as a6, type RuntimeArtifactsAccessor as a7, type RuntimeAvailability as a8, type RuntimeWakeDetail as a9, type StreamChunkOptions as aA, type StreamDataTransport as aB, type TransportEstablishedNotify as aC, TransportNegotiator as aD, type TransportOfferRequest as aE, type TransportOfferResponse as aF, TransportSession as aG, type TransportSessionOptions as aH, TransportSessionSignaling as aI, type TransportState as aJ, type VideoPlayoutOptions as aK, WT_CONTROL_FRAME_MAX as aL, WT_DATA_STREAM_VERSION as aM, type WatchGenerationTickOptions as aN, type WtAudioLaneSeam as aO, type WtAudioUplinkSeam as aP, WtControlDecoder as aQ, type WtControlMessage as aR, type WtDataEnvelope as aS, type WtDataLaneSink as aT, WtDataStreamParser as aU, WtDataUplinkSender as aV, type WtVideoUplinkSeam as aW, allocateSession as aX, computeBackoffDelay as aY, consumeWtDataStreams as aZ, createPresence as a_, type RuntimeWakeGolden as aa, type RuntimeWakeReasonCode as ab, SIGNALING_PROTOCOL_VERSION as ac, STREAM_END as ad, type Session as ae, type SessionDiagnostic as af, type SessionDirectoryRequestOptions as ag, type SessionDocument as ah, SessionDocumentImpl as ai, type SessionEndResult as aj, type SessionFailureKind as ak, type SessionNameSource as al, type SessionPhase as am, type SessionPhaseError as an, type SessionPhaseName as ao, type SessionStartOptions as ap, type SessionStatsOptions as aq, type SessionStatsSample as ar, type SessionStatus as as, type SessionStream as at, type SessionText as au, type SignalCarrier as av, type Signaling as aw, type StartSessionOptions as ax, type Store as ay, type StoreOptions as az, type ActivationEvent as b, decodeStreamEnvelope as b0, deriveYjsServerUrl as b1, derivedLegName as b2, derivedLegRole as b3, encodeStreamEnvelope as b4, encodeWtControlFrame as b5, isPendingRecording as b6, isRetryableSessionError as b7, mediaRecorderChunkSource as b8, parseDgramHeader as b9, prewake as ba, releaseSessionBeacon as bb, streamDataLabel as bc, transportStreamData as bd, watchGenerationTick as be, writeDgramHeader as bf, type ActivationState as c, type ActivitySignalMode as d, type AllocateSessionOptions as e, type AllocatedSession as f, type App as g, type AppOptions as h, type AttachOptions as i, type AudioPlayoutOptions as j, BACKOFF_MAX_ATTEMPTS as k, BACKOFF_MAX_MS as l, type ChannelMessage as m, ChannelMultiplexer as n, type ChannelName as o, type ChunkReadable as p, DGRAM_HEADER_BYTES as q, DOC_SYNC_WIRE_CONTRACT_VERSION as r, DeferredChannelMultiplexer as s, DeferredDocConnector as t, type DerivedLegRole as u, type DgramHeader as v, type DocConnection as w, type DocConnectionState as x, type DocConnector as y, type DocServerUrlResolver as z };