@canonmsg/agent-sdk 5.1.2 → 5.1.4

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/README.md CHANGED
@@ -47,7 +47,7 @@ No additional dependencies required — the SDK uses native `fetch` and `Readabl
47
47
  | `runtimeControls` | `RuntimeControlHandlers` | `undefined` | Optional interrupt / stop-clear handlers for Canon working-state controls |
48
48
  | `runtimeControlSurface` | `'agent' \| 'host'` | `'agent'` | Runtime publishing surface. Use `host` when this SDK agent owns live runtime controls. |
49
49
  | `runtimePrimitives` | `RuntimePrimitiveHandlers` | `undefined` | Optional typed primitive command handlers for descriptor-backed runtime commands |
50
- | `sessionState` | `boolean` | `false` | Publish RTDB session-state for the conversations this agent is active in |
50
+ | `sessionState` | `boolean` | `false` | Publish runtime-applied state to the canonical agent-session snapshot |
51
51
 
52
52
  ### Optional runtime controls
53
53
 
@@ -1,4 +1,4 @@
1
- import { ApprovalManager, RuntimeRequestManager, runtimeInputDescriptor, runtimeCardDescriptor, CanonClient, ControlChannelPoller, buildCanonTurnContextV2, buildCanonGroupContext, buildParticipationHistorySnapshot, createTurnOutputController, createRuntimeStatePublisher, createTypingStatusPublisher, diffCanonMemberIds, FINAL_MESSAGE_HANDOFF_MS, RUNTIME_NEW_SESSION_ACTION, RUNTIME_STOP_ACTION, RUNTIME_STOP_AND_DROP_ACTION, buildRuntimeCardOutcome, buildRuntimeInputOutcome, initRTDBAuth, normalizeRuntimeCommandDescriptors, normalizeTurnMetadata, reachOutToCanonContact, resolveCanonReplyContext, resolveMessageActiveSelfContextId, resolveRuntimeProvenance, selectActiveSelfContexts, renderCanonHostInboundContent, sendMessageWithRetry, } from '@canonmsg/core';
1
+ import { ApprovalManager, RuntimeRequestManager, runtimeInputDescriptor, runtimeCardDescriptor, CanonClient, DEFAULT_BASE_URL, ControlChannelPoller, buildCanonTurnContextV2, buildCanonGroupContext, buildParticipationHistorySnapshot, createTurnOutputController, createRuntimeStatePublisher, createTypingStatusPublisher, diffCanonMemberIds, FINAL_MESSAGE_HANDOFF_MS, RUNTIME_NEW_SESSION_ACTION, RUNTIME_STOP_ACTION, RUNTIME_STOP_AND_DROP_ACTION, buildRuntimeCardOutcome, buildRuntimeInputOutcome, initRTDBAuth, normalizeRuntimeCommandDescriptors, normalizeTurnMetadata, reachOutToCanonContact, resolveCanonReplyContext, resolveMessageActiveSelfContextId, resolveRuntimeProvenance, selectActiveSelfContexts, renderCanonHostInboundContent, sendMessageWithRetry, } from '@canonmsg/core';
2
2
  import { createHash, randomUUID } from 'node:crypto';
3
3
  import { AuthManager } from './auth.js';
4
4
  import { Debouncer } from './debouncer.js';
@@ -292,7 +292,7 @@ export class CanonAgent {
292
292
  sseConnectedLogged = false;
293
293
  constructor(options) {
294
294
  this.options = {
295
- baseUrl: 'https://api-6m6mlelskq-uc.a.run.app',
295
+ baseUrl: DEFAULT_BASE_URL,
296
296
  deliveryMode: 'auto',
297
297
  debounceMs: 2000,
298
298
  historyLimit: 50,
package/dist/types.d.ts CHANGED
@@ -270,7 +270,7 @@ export interface CanonAgentOptions {
270
270
  /** Optional typed runtime primitive handlers. Enables descriptor-backed command controls when provided. */
271
271
  runtimePrimitives?: RuntimePrimitiveHandlers;
272
272
  /**
273
- * Enable RTDB session-state reporting. Off by default.
273
+ * Enable canonical agent-session state reporting. Off by default.
274
274
  * Turn-state reporting is automatic while handlers run.
275
275
  */
276
276
  sessionState?: boolean;
@@ -313,7 +313,12 @@ export type ReachOutResult = {
313
313
  reason: string;
314
314
  };
315
315
  export interface ReachOutOptions {
316
- /** Optional first message to send when admission is `allowed`. */
316
+ /**
317
+ * Optional first message; sent now when allowed or parked for exact delivery
318
+ * after approval when it is visible text <= 4 KiB. Attachments and hidden
319
+ * session setup cannot be parked; a setup-requiring coding target returns
320
+ * `setup_required` before a contact request is created.
321
+ */
317
322
  text?: string;
318
323
  /** Optional contact-request note. Defaults to `text` when admission is `request-required`. */
319
324
  requestMessage?: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@canonmsg/agent-sdk",
3
- "version": "5.1.2",
3
+ "version": "5.1.4",
4
4
  "description": "Canon Agent SDK — build AI agents that participate in Canon conversations",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -28,7 +28,7 @@
28
28
  "node": ">=18.0.0"
29
29
  },
30
30
  "dependencies": {
31
- "@canonmsg/core": "^4.3.0"
31
+ "@canonmsg/core": "^5.0.1"
32
32
  },
33
33
  "publishConfig": {
34
34
  "access": "public"