@openclaw/gateway-client 2026.11.3 → 2026.11.5-beta.2

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,4 +1,5 @@
1
- import { n as GatewayProtocolRequestOptions } from "./protocol-request-CtVhe3Bj.mjs";
1
+ import { n as GatewayProtocolRequestOptions } from "./protocol-request-CRDNYiYG.mjs";
2
+ import { ErrorShape, SessionsMessagesSubscribeParams } from "@openclaw/gateway-protocol";
2
3
  //#region packages/gateway-client/src/device-auth.d.ts
3
4
  declare function normalizeDeviceMetadataForAuth(value?: string | null): string;
4
5
  type DeviceAuthPayloadParams = {
@@ -90,6 +91,7 @@ declare function hasSessionProjectionAcceptedFinal(run: TerminalProjectionRun |
90
91
  type SessionProjectionGatewayRunEvent = {
91
92
  state?: unknown;
92
93
  yielded?: unknown;
94
+ suppressErrorNotice?: unknown;
93
95
  seq?: unknown;
94
96
  deltaText?: unknown;
95
97
  replace?: unknown;
@@ -133,6 +135,7 @@ type SessionProjectionRun = {
133
135
  stopReason?: string;
134
136
  errorKind?: string;
135
137
  errorMessage?: string;
138
+ suppressErrorNotice?: boolean;
136
139
  };
137
140
  type SessionProjectionState = {
138
141
  scope: SessionProjectionScope;
@@ -197,11 +200,21 @@ type GatewaySessionMessageSubscription = {
197
200
  mode?: "narration";
198
201
  includeApprovals?: true;
199
202
  approvalReplay?: unknown;
203
+ /** One-shot snapshot owned by the acquisition that requested it. */
204
+ initialHistory?: GatewaySessionInitialHistoryResult;
205
+ };
206
+ type GatewaySessionInitialHistoryResult = {
207
+ ok: true;
208
+ payload: unknown;
209
+ } | {
210
+ ok: false;
211
+ error: ErrorShape;
200
212
  };
201
213
  type GatewaySessionMessageSubscriptionOptions = {
202
214
  agentId?: string | null;
203
215
  mode?: "narration";
204
216
  includeApprovals?: boolean;
217
+ initialHistory?: SessionsMessagesSubscribeParams["initialHistory"];
205
218
  };
206
219
  type GatewaySessionMessageSubscriptionCoordinatorOptions = {
207
220
  keysEquivalent?: (left: string, right: string) => boolean;
@@ -223,4 +236,4 @@ declare function getGatewaySessionMessageSubscriptionCoordinator(client: Gateway
223
236
  declare function resetGatewaySessionMessageSubscriptionCoordinator(client: GatewaySessionMessageRequestClient): void;
224
237
  declare function releaseGatewaySessionMessageSubscription(subscription: GatewaySessionMessageSubscription): Promise<void>;
225
238
  //#endregion
226
- export { normalizeSessionProjectionRunId as A, reduceSessionProjectionRunEvent as C, SessionMessageIdentity as D, SessionMessageEnvelope as E, gatewayOriginScope as F, mergeChatStreamMessage as I, buildDeviceAuthPayload as L, readSessionMessageIdentity as M, readSessionMessageSequence as N, SessionProjectionEntry as O, gatewayCredentialScope as P, buildDeviceAuthPayloadV3 as R, SessionProjectionRunTransition as S, readSessionProjectionFinalMessageIdentity as T, reconcileSessionProjectionSnapshot as _, GatewaySessionMessageSubscriptionOptions as a, projectSessionTerminalReplyMessage as b, resetGatewaySessionMessageSubscriptionCoordinator as c, SessionProjectionRunStatus as d, SessionProjectionScope as f, projectLiveSessionMessage as g, createSessionProjection as h, GatewaySessionMessageSubscriptionCoordinatorOptions as i, readAssistantStreamSegmentIdentity as j, isLocallyOptimisticSessionMessage as k, SessionProjectionEvent as l, SessionProjectionState as m, GatewaySessionMessageSubscription as n, getGatewaySessionMessageSubscriptionCoordinator as o, SessionProjectionSnapshotOptions as p, GatewaySessionMessageSubscriptionCoordinator as r, releaseGatewaySessionMessageSubscription as s, GatewaySessionMessageRequestClient as t, SessionProjectionRun as u, reduceSessionProjection as v, hasSessionProjectionAcceptedFinal as w, SessionProjectionGatewayRunEvent as x, isSessionProjectionErrorMessage as y, normalizeDeviceMetadataForAuth as z };
239
+ export { isLocallyOptimisticSessionMessage as A, normalizeDeviceMetadataForAuth as B, SessionProjectionRunTransition as C, SessionMessageEnvelope as D, readSessionProjectionFinalMessageIdentity as E, gatewayCredentialScope as F, gatewayOriginScope as I, mergeChatStreamMessage as L, readAssistantStreamSegmentIdentity as M, readSessionMessageIdentity as N, SessionMessageIdentity as O, readSessionMessageSequence as P, buildDeviceAuthPayload as R, SessionProjectionGatewayRunEvent as S, hasSessionProjectionAcceptedFinal as T, projectLiveSessionMessage as _, GatewaySessionMessageSubscriptionCoordinatorOptions as a, isSessionProjectionErrorMessage as b, releaseGatewaySessionMessageSubscription as c, SessionProjectionRun as d, SessionProjectionRunStatus as f, createSessionProjection as g, SessionProjectionState as h, GatewaySessionMessageSubscriptionCoordinator as i, normalizeSessionProjectionRunId as j, SessionProjectionEntry as k, resetGatewaySessionMessageSubscriptionCoordinator as l, SessionProjectionSnapshotOptions as m, GatewaySessionMessageRequestClient as n, GatewaySessionMessageSubscriptionOptions as o, SessionProjectionScope as p, GatewaySessionMessageSubscription as r, getGatewaySessionMessageSubscriptionCoordinator as s, GatewaySessionInitialHistoryResult as t, SessionProjectionEvent as u, reconcileSessionProjectionSnapshot as v, reduceSessionProjectionRunEvent as w, projectSessionTerminalReplyMessage as x, reduceSessionProjection as y, buildDeviceAuthPayloadV3 as z };
@@ -85,9 +85,6 @@ function getConnectChallengeTimeoutMsFromEnv(env = process.env) {
85
85
  if (parsed !== void 0) return resolveSafeTimeoutDelayMs(parsed);
86
86
  }
87
87
  }
88
- function normalizePositiveTimeoutMs(timeoutMs) {
89
- return typeof timeoutMs === "number" && Number.isFinite(timeoutMs) && timeoutMs > 0 ? resolveSafeTimeoutDelayMs(timeoutMs) : void 0;
90
- }
91
88
  /** Resolves the client watchdog timeout using explicit, env, then preauth defaults. */
92
89
  function resolveConnectChallengeTimeoutMs(timeoutMs, params) {
93
90
  const configuredPreauthTimeoutMs = resolvePreauthHandshakeTimeoutMs({
@@ -108,8 +105,8 @@ function resolvePreauthHandshakeTimeoutMs(params) {
108
105
  const parsed = parseStrictPositiveInteger(configuredTimeout);
109
106
  if (parsed !== void 0) return resolveSafeTimeoutDelayMs(parsed);
110
107
  }
111
- const configured = normalizePositiveTimeoutMs(params?.configuredTimeoutMs);
112
- if (configured !== void 0) return configured;
108
+ const configured = params?.configuredTimeoutMs;
109
+ if (typeof configured === "number" && Number.isFinite(configured) && configured > 0) return resolveSafeTimeoutDelayMs(configured);
113
110
  return DEFAULT_PREAUTH_HANDSHAKE_TIMEOUT_MS;
114
111
  }
115
112
  //#endregion
package/dist/timeouts.mjs CHANGED
@@ -1,2 +1 @@
1
- import { a as MIN_CONNECT_CHALLENGE_TIMEOUT_MS, c as clearGatewayConnectTimeout, d as resolveFiniteTimeoutDelayMs, f as resolvePreauthHandshakeTimeoutMs, i as MAX_SAFE_TIMEOUT_DELAY_MS, l as getConnectChallengeTimeoutMsFromEnv, m as startGatewayConnectTimeout, n as DEFAULT_PREAUTH_HANDSHAKE_TIMEOUT_MS, o as addSafeTimeoutDelayGraceMs, p as resolveSafeTimeoutDelayMs, r as MAX_CONNECT_CHALLENGE_TIMEOUT_MS, s as clampConnectChallengeTimeoutMs, t as DEFAULT_GATEWAY_REQUEST_TIMEOUT_MS, u as resolveConnectChallengeTimeoutMs } from "./timeouts-F2UKsnjG.mjs";
2
- export { DEFAULT_GATEWAY_REQUEST_TIMEOUT_MS, DEFAULT_PREAUTH_HANDSHAKE_TIMEOUT_MS, MAX_CONNECT_CHALLENGE_TIMEOUT_MS, MAX_SAFE_TIMEOUT_DELAY_MS, MIN_CONNECT_CHALLENGE_TIMEOUT_MS, addSafeTimeoutDelayGraceMs, clampConnectChallengeTimeoutMs, clearGatewayConnectTimeout, getConnectChallengeTimeoutMsFromEnv, resolveConnectChallengeTimeoutMs, resolveFiniteTimeoutDelayMs, resolvePreauthHandshakeTimeoutMs, resolveSafeTimeoutDelayMs, startGatewayConnectTimeout };
1
+ export { t as DEFAULT_GATEWAY_REQUEST_TIMEOUT_MS, n as DEFAULT_PREAUTH_HANDSHAKE_TIMEOUT_MS, r as MAX_CONNECT_CHALLENGE_TIMEOUT_MS, i as MAX_SAFE_TIMEOUT_DELAY_MS, a as MIN_CONNECT_CHALLENGE_TIMEOUT_MS, o as addSafeTimeoutDelayGraceMs, s as clampConnectChallengeTimeoutMs, c as clearGatewayConnectTimeout, l as getConnectChallengeTimeoutMsFromEnv, u as resolveConnectChallengeTimeoutMs, d as resolveFiniteTimeoutDelayMs, f as resolvePreauthHandshakeTimeoutMs, p as resolveSafeTimeoutDelayMs, m as startGatewayConnectTimeout } from "./timeouts-BBVOnLnf.mjs";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openclaw/gateway-client",
3
- "version": "2026.11.3",
3
+ "version": "2026.11.5-beta.2",
4
4
  "description": "Reference WebSocket client for the OpenClaw Gateway protocol",
5
5
  "keywords": [
6
6
  "client",
@@ -62,7 +62,8 @@
62
62
  }
63
63
  },
64
64
  "dependencies": {
65
- "@openclaw/gateway-protocol": "2026.11.3",
65
+ "@noble/hashes": "2.4.0",
66
+ "@openclaw/gateway-protocol": "2026.11.5-beta.2",
66
67
  "ipaddr.js": "2.5.0",
67
68
  "ws": "8.22.0"
68
69
  },