@openacp/cli 2026.410.2 → 2026.413.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.
@@ -79,6 +79,19 @@ declare function createTurnContext(sourceAdapterId: string, responseAdapterId?:
79
79
  declare function getEffectiveTarget(ctx: TurnContext): string | null;
80
80
  declare function isSystemEvent(event: AgentEvent): boolean;
81
81
 
82
+ /**
83
+ * Per-turn context bag threaded through all turn-lifecycle middleware hooks.
84
+ *
85
+ * Core fills in `turnId`; plugins attach arbitrary keys at any hook and read
86
+ * them at subsequent hooks in the same turn. The object is mutable by design —
87
+ * plugins collaborating through meta should use namespaced keys to avoid clashes
88
+ * (e.g., `meta['workspace.sender']` not `meta.sender`).
89
+ */
90
+ interface TurnMeta {
91
+ /** The turn's unique ID — same value passed to session.enqueuePrompt(). */
92
+ turnId: string;
93
+ [key: string]: unknown;
94
+ }
82
95
  /**
83
96
  * A file attachment sent to or received from an agent.
84
97
  *
@@ -451,6 +464,10 @@ interface SessionRecord<P = Record<string, unknown>> {
451
464
  firstAgent?: string;
452
465
  currentPromptCount?: number;
453
466
  agentSwitchHistory?: AgentSwitchEntry[];
467
+ /** userId of the user who created this session (from identity system). */
468
+ createdBy?: string;
469
+ /** userId[] of all users who have sent messages in this session. */
470
+ participants?: string[];
454
471
  acpState?: {
455
472
  configOptions?: ConfigOption[];
456
473
  agentCapabilities?: AgentCapabilities;
@@ -734,6 +751,16 @@ interface IChannelAdapter {
734
751
  /** Flush skill commands that were queued before threadId was available. */
735
752
  flushPendingSkillCommands?(sessionId: string): Promise<void>;
736
753
  cleanupSessionState?(sessionId: string): Promise<void>;
754
+ /** Send a notification directly to a user by platform ID. Best-effort delivery. */
755
+ sendUserNotification?(platformId: string, message: NotificationMessage, options?: {
756
+ via?: 'dm' | 'thread' | 'topic';
757
+ topicId?: string;
758
+ sessionId?: string;
759
+ platformMention?: {
760
+ platformUsername?: string;
761
+ platformId: string;
762
+ };
763
+ }): Promise<void>;
737
764
  }
738
765
  /**
739
766
  * Original base class for channel adapters. Provides default no-op implementations
@@ -764,6 +791,7 @@ declare abstract class ChannelAdapter<TCore = unknown> implements IChannelAdapte
764
791
  cleanupSkillCommands(_sessionId: string): Promise<void>;
765
792
  cleanupSessionState(_sessionId: string): Promise<void>;
766
793
  archiveSessionTopic(_sessionId: string): Promise<void>;
794
+ sendUserNotification(_platformId: string, _message: NotificationMessage, _options?: any): Promise<void>;
767
795
  }
768
796
 
769
- export { type SessionModelState as $, type Attachment as A, type ConfigSelectGroup as B, type ConfigOption as C, type DisplayVerbosity as D, type ContentBlock as E, type ModelInfo as F, type NewSessionResponse as G, type PermissionOption as H, type IChannelAdapter as I, type PromptResponse as J, KIND_ICONS as K, type RegistryBinaryTarget as L, type McpServerConfig as M, type NotificationMessage as N, type OutgoingMessage as O, type PermissionRequest as P, type RegistryDistribution as Q, type RegistryAgent as R, type StopReason as S, type TurnContext as T, type UsageRecord as U, type ViewerLinks as V, STATUS_ICONS as W, type SessionListItem as X, type SessionListResponse as Y, type SessionMode as Z, type SessionModeState as _, type AgentEvent as a, type TelegramPlatformData as a0, type ToolUpdateMeta as a1, createTurnContext as a2, getEffectiveTarget as a3, isSystemEvent as a4, type AgentCapabilities as b, type AgentDefinition as c, type SetConfigOptionValue as d, type InstalledAgent as e, type AgentListItem as f, type AvailabilityResult as g, type InstallProgress as h, type InstallResult as i, type SessionStatus as j, type AgentSwitchEntry as k, type AgentCommand as l, type TurnRouting as m, type SessionRecord as n, type UsageRecordEvent as o, type IncomingMessage as p, type ChannelConfig as q, type AdapterCapabilities as r, type ToolCallMeta as s, type OutputMode as t, type PlanEntry as u, type AgentDistribution as v, type AuthMethod as w, type AuthenticateRequest as x, ChannelAdapter as y, type ConfigSelectChoice as z };
797
+ export { type SessionModeState as $, type Attachment as A, type ConfigSelectChoice as B, type ConfigOption as C, type DisplayVerbosity as D, type ConfigSelectGroup as E, type ContentBlock as F, type ModelInfo as G, type NewSessionResponse as H, type IChannelAdapter as I, type PermissionOption as J, KIND_ICONS as K, type PromptResponse as L, type McpServerConfig as M, type NotificationMessage as N, type OutgoingMessage as O, type PermissionRequest as P, type RegistryBinaryTarget as Q, type RegistryAgent as R, type StopReason as S, type TurnMeta as T, type UsageRecord as U, type ViewerLinks as V, type RegistryDistribution as W, STATUS_ICONS as X, type SessionListItem as Y, type SessionListResponse as Z, type SessionMode as _, type AgentEvent as a, type SessionModelState as a0, type TelegramPlatformData as a1, type ToolUpdateMeta as a2, createTurnContext as a3, getEffectiveTarget as a4, isSystemEvent as a5, type SessionStatus as b, type AgentCapabilities as c, type AgentDefinition as d, type SetConfigOptionValue as e, type InstalledAgent as f, type AgentListItem as g, type AvailabilityResult as h, type InstallProgress as i, type InstallResult as j, type TurnContext as k, type AgentSwitchEntry as l, type AgentCommand as m, type TurnRouting as n, type SessionRecord as o, type UsageRecordEvent as p, type IncomingMessage as q, type ChannelConfig as r, type AdapterCapabilities as s, type ToolCallMeta as t, type OutputMode as u, type PlanEntry as v, type AgentDistribution as w, type AuthMethod as x, type AuthenticateRequest as y, ChannelAdapter as z };