@ai-matrx/desktop-protocol 0.17.8 → 0.17.10

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/dist/index.d.cts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { z } from 'zod';
2
- import { O as OpName } from './models-B2PuTc6a.cjs';
3
- export { B as BEARER_PREFIX, g as CLOSE_RULES, h as CancelMsg, j as ClientToCoreMsg, e as ClientType, k as CloseAction, l as CloseCode, m as CloseCodeValue, C as CloseOutcome, n as CloseRule, o as CoreToClientMsg, p as CreditMsg, D as DesktopProtocolError, d as EVENTS, q as EndMsg, E as EndReason, r as ErrorCode, s as ErrorCodeName, t as ErrorData, u as ErrorMsg, v as ErrorReason, w as ErrorReasonName, x as EventMsg, y as EventName, F as FsPatchEditFailure, H as HelloMsg, L as Limits, z as MlInstallPhase, A as MlInstallProgress, f as MlProgress, G as MlRuntimeState, I as MlServiceState, J as MlServiceStatus, K as MlStatusParams, N as MlStatusResult, P as ModelsInstallParams, Q as ModelsInstallResult, R as ModelsProgressEvent, U as ModelsStatusParams, V as ModelsStatusResult, X as ModelsTranscribeParams, M as ModelsTranscribeResult, Y as NAMED_SCHEMAS, Z as NamedSchemaId, c as OPS, _ as OpDescriptor, a as OpParams, b as OpResult, $ as OpSpec, a0 as PING_TEXT, a1 as PONG_TEXT, a2 as ProtocolErrorBody, a3 as RelayMsg, a4 as RequestMsg, a5 as ResponseMsg, a6 as SERVICES, a7 as SUBPROTOCOL, a8 as ServiceId, a9 as ServiceOpName, aa as ServiceOpSpec, ab as ServiceSpec, S as StreamMeta, ac as StreamMsg, ad as TranscriptSegment, T as TranscriptionModelId, ae as TranscriptionModelInfo, W as Welcome, af as closeRule, i as isDesktopProtocolError, ag as isTerminalClose } from './models-B2PuTc6a.cjs';
2
+ import { O as OpName } from './models-BcBSKFeq.cjs';
3
+ export { B as BEARER_PREFIX, g as CLOSE_RULES, h as CancelMsg, j as ClientToCoreMsg, e as ClientType, k as CloseAction, l as CloseCode, m as CloseCodeValue, C as CloseOutcome, n as CloseRule, o as CoreToClientMsg, p as CreditMsg, D as DesktopProtocolError, d as EVENTS, q as EndMsg, E as EndReason, r as ErrorCode, s as ErrorCodeName, t as ErrorData, u as ErrorMsg, v as ErrorReason, w as ErrorReasonName, x as EventMsg, y as EventName, F as FsPatchEditFailure, H as HelloMsg, L as Limits, z as MlInstallPhase, A as MlInstallProgress, f as MlProgress, G as MlRuntimeState, I as MlServiceState, J as MlServiceStatus, K as MlStatusParams, N as MlStatusResult, P as ModelsInstallParams, Q as ModelsInstallResult, R as ModelsProgressEvent, U as ModelsStatusParams, V as ModelsStatusResult, X as ModelsTranscribeParams, M as ModelsTranscribeResult, Y as NAMED_SCHEMAS, Z as NamedSchemaId, c as OPS, _ as OpDescriptor, a as OpParams, b as OpResult, $ as OpSpec, a0 as PING_TEXT, a1 as PONG_TEXT, a2 as ProtocolErrorBody, a3 as RelayMsg, a4 as RequestMsg, a5 as ResponseMsg, a6 as SERVICES, a7 as SUBPROTOCOL, a8 as ServiceId, a9 as ServiceOpName, aa as ServiceOpSpec, ab as ServiceSpec, S as StreamMeta, ac as StreamMsg, ad as TranscriptSegment, T as TranscriptionModelId, ae as TranscriptionModelInfo, W as Welcome, af as closeRule, i as isDesktopProtocolError, ag as isTerminalClose } from './models-BcBSKFeq.cjs';
4
4
  export { BROADCAST_CID, DecodedFrame, FRAME_HEADER_BYTES, FRAME_STRUCT_FORMAT, FRAME_VERSION, FrameChannel, FrameChannelValue, FrameFlag, assertFrameHeader, connectionEndFrame, decodeFrame, encodeFrame, hasFlag, isConnectionEnd, readCid, stampCid } from './frame.cjs';
5
5
 
6
6
  /** @ai-matrx/desktop-protocol — version and primitive schemas. Schema source: lint-enforced rules in scripts/check-schema-source.mjs. */
@@ -23,10 +23,11 @@ declare const PROTOCOL_MAJOR: 1;
23
23
  * 1.8 — `apps.chats.*` / `apps.projects.*`: a coding app's chats, windows, pins and projects, live.
24
24
  * 1.9 — chats placed in windows / held, several filed at once, projects renamed / archived / copied;
25
25
  * the list says when it is a saved copy being re-read (`updating`) and when it is not live.
26
+ * 1.14 — a chat row carries its original title, where it came from, and the person's rename.
26
27
  */
27
- declare const PROTOCOL_MINOR: 12;
28
+ declare const PROTOCOL_MINOR: 14;
28
29
  /** This package's version as the wire spells it ("major.minor"): hello, welcome, relay status. */
29
- declare const PROTOCOL_VERSION: "1.12";
30
+ declare const PROTOCOL_VERSION: "1.14";
30
31
  /** Internal building blocks — deliberately unnamed in $defs (inlined wherever used). */
31
32
  declare const u32: z.ZodInt;
32
33
  declare const nonNegInt: z.ZodInt;
@@ -1384,8 +1385,22 @@ declare const ChatRow: z.ZodObject<{
1384
1385
  cache_warm: z.ZodBoolean;
1385
1386
  cache_minutes_left: z.ZodInt;
1386
1387
  }, z.core.$strict>>;
1388
+ app_project: z.ZodOptional<z.ZodObject<{
1389
+ id: z.ZodString;
1390
+ name: z.ZodString;
1391
+ }, z.core.$strict>>;
1392
+ tokens: z.ZodOptional<z.ZodInt>;
1393
+ original_title: z.ZodOptional<z.ZodString>;
1394
+ title_source: z.ZodOptional<z.ZodString>;
1395
+ title_override: z.ZodOptional<z.ZodString>;
1387
1396
  }, z.core.$strict>;
1388
1397
  type ChatRow = z.output<typeof ChatRow>;
1398
+ /** 1.13: a project the app itself keeps (Codex's sidebar projects), never ours and never written. */
1399
+ declare const ChatAppProject: z.ZodObject<{
1400
+ id: z.ZodString;
1401
+ name: z.ZodString;
1402
+ }, z.core.$strict>;
1403
+ type ChatAppProject = z.output<typeof ChatAppProject>;
1389
1404
  /** 1.10: a chat's family: the conversation it was forked from, or the original it is a copy of. */
1390
1405
  declare const ChatFamily: z.ZodObject<{
1391
1406
  id: z.ZodString;
@@ -1451,6 +1466,14 @@ declare const AppsChatsListResult: z.ZodObject<{
1451
1466
  cache_warm: z.ZodBoolean;
1452
1467
  cache_minutes_left: z.ZodInt;
1453
1468
  }, z.core.$strict>>;
1469
+ app_project: z.ZodOptional<z.ZodObject<{
1470
+ id: z.ZodString;
1471
+ name: z.ZodString;
1472
+ }, z.core.$strict>>;
1473
+ tokens: z.ZodOptional<z.ZodInt>;
1474
+ original_title: z.ZodOptional<z.ZodString>;
1475
+ title_source: z.ZodOptional<z.ZodString>;
1476
+ title_override: z.ZodOptional<z.ZodString>;
1454
1477
  }, z.core.$strict>>;
1455
1478
  new_window_ms: z.ZodInt;
1456
1479
  updating: z.ZodOptional<z.ZodBoolean>;
@@ -1527,6 +1550,14 @@ declare const AppsProjectsFileResult: z.ZodObject<{
1527
1550
  cache_warm: z.ZodBoolean;
1528
1551
  cache_minutes_left: z.ZodInt;
1529
1552
  }, z.core.$strict>>;
1553
+ app_project: z.ZodOptional<z.ZodObject<{
1554
+ id: z.ZodString;
1555
+ name: z.ZodString;
1556
+ }, z.core.$strict>>;
1557
+ tokens: z.ZodOptional<z.ZodInt>;
1558
+ original_title: z.ZodOptional<z.ZodString>;
1559
+ title_source: z.ZodOptional<z.ZodString>;
1560
+ title_override: z.ZodOptional<z.ZodString>;
1530
1561
  }, z.core.$strict>;
1531
1562
  project: z.ZodObject<{
1532
1563
  id: z.ZodString;
@@ -1582,6 +1613,14 @@ declare const AppsProjectsUnfileResult: z.ZodObject<{
1582
1613
  cache_warm: z.ZodBoolean;
1583
1614
  cache_minutes_left: z.ZodInt;
1584
1615
  }, z.core.$strict>>;
1616
+ app_project: z.ZodOptional<z.ZodObject<{
1617
+ id: z.ZodString;
1618
+ name: z.ZodString;
1619
+ }, z.core.$strict>>;
1620
+ tokens: z.ZodOptional<z.ZodInt>;
1621
+ original_title: z.ZodOptional<z.ZodString>;
1622
+ title_source: z.ZodOptional<z.ZodString>;
1623
+ title_override: z.ZodOptional<z.ZodString>;
1585
1624
  }, z.core.$strict>;
1586
1625
  }, z.core.$strict>;
1587
1626
  type AppsProjectsUnfileResult = z.output<typeof AppsProjectsUnfileResult>;
@@ -1631,6 +1670,14 @@ declare const AppsChatsStarResult: z.ZodObject<{
1631
1670
  cache_warm: z.ZodBoolean;
1632
1671
  cache_minutes_left: z.ZodInt;
1633
1672
  }, z.core.$strict>>;
1673
+ app_project: z.ZodOptional<z.ZodObject<{
1674
+ id: z.ZodString;
1675
+ name: z.ZodString;
1676
+ }, z.core.$strict>>;
1677
+ tokens: z.ZodOptional<z.ZodInt>;
1678
+ original_title: z.ZodOptional<z.ZodString>;
1679
+ title_source: z.ZodOptional<z.ZodString>;
1680
+ title_override: z.ZodOptional<z.ZodString>;
1634
1681
  }, z.core.$strict>;
1635
1682
  }, z.core.$strict>;
1636
1683
  type AppsChatsStarResult = z.output<typeof AppsChatsStarResult>;
@@ -1695,6 +1742,14 @@ declare const AppsChatsPlaceResult: z.ZodObject<{
1695
1742
  cache_warm: z.ZodBoolean;
1696
1743
  cache_minutes_left: z.ZodInt;
1697
1744
  }, z.core.$strict>>;
1745
+ app_project: z.ZodOptional<z.ZodObject<{
1746
+ id: z.ZodString;
1747
+ name: z.ZodString;
1748
+ }, z.core.$strict>>;
1749
+ tokens: z.ZodOptional<z.ZodInt>;
1750
+ original_title: z.ZodOptional<z.ZodString>;
1751
+ title_source: z.ZodOptional<z.ZodString>;
1752
+ title_override: z.ZodOptional<z.ZodString>;
1698
1753
  }, z.core.$strict>;
1699
1754
  message: z.ZodString;
1700
1755
  }, z.core.$strict>;
@@ -1747,6 +1802,14 @@ declare const AppsProjectsFileManyResult: z.ZodObject<{
1747
1802
  cache_warm: z.ZodBoolean;
1748
1803
  cache_minutes_left: z.ZodInt;
1749
1804
  }, z.core.$strict>>;
1805
+ app_project: z.ZodOptional<z.ZodObject<{
1806
+ id: z.ZodString;
1807
+ name: z.ZodString;
1808
+ }, z.core.$strict>>;
1809
+ tokens: z.ZodOptional<z.ZodInt>;
1810
+ original_title: z.ZodOptional<z.ZodString>;
1811
+ title_source: z.ZodOptional<z.ZodString>;
1812
+ title_override: z.ZodOptional<z.ZodString>;
1750
1813
  }, z.core.$strict>>;
1751
1814
  project: z.ZodObject<{
1752
1815
  id: z.ZodString;
@@ -1829,6 +1892,8 @@ declare const AccountUsage: z.ZodObject<{
1829
1892
  live: z.ZodBoolean;
1830
1893
  weekly_resets_at_ms: z.ZodNullable<z.ZodInt>;
1831
1894
  weekly_reset_official: z.ZodNullable<z.ZodBoolean>;
1895
+ plan: z.ZodOptional<z.ZodString>;
1896
+ credits: z.ZodOptional<z.ZodString>;
1832
1897
  }, z.core.$strict>;
1833
1898
  type AccountUsage = z.output<typeof AccountUsage>;
1834
1899
  /** One window's account's next weekly reset and where the time came from. */
@@ -1885,6 +1950,8 @@ declare const AppsAccountsUsageResult: z.ZodObject<{
1885
1950
  live: z.ZodBoolean;
1886
1951
  weekly_resets_at_ms: z.ZodNullable<z.ZodInt>;
1887
1952
  weekly_reset_official: z.ZodNullable<z.ZodBoolean>;
1953
+ plan: z.ZodOptional<z.ZodString>;
1954
+ credits: z.ZodOptional<z.ZodString>;
1888
1955
  }, z.core.$strict>>;
1889
1956
  problem: z.ZodOptional<z.ZodString>;
1890
1957
  }, z.core.$strict>;
@@ -1989,6 +2056,14 @@ declare const AppsProjectsMoveResult: z.ZodObject<{
1989
2056
  cache_warm: z.ZodBoolean;
1990
2057
  cache_minutes_left: z.ZodInt;
1991
2058
  }, z.core.$strict>>;
2059
+ app_project: z.ZodOptional<z.ZodObject<{
2060
+ id: z.ZodString;
2061
+ name: z.ZodString;
2062
+ }, z.core.$strict>>;
2063
+ tokens: z.ZodOptional<z.ZodInt>;
2064
+ original_title: z.ZodOptional<z.ZodString>;
2065
+ title_source: z.ZodOptional<z.ZodString>;
2066
+ title_override: z.ZodOptional<z.ZodString>;
1992
2067
  }, z.core.$strict>;
1993
2068
  project: z.ZodObject<{
1994
2069
  id: z.ZodString;
@@ -3777,6 +3852,17 @@ declare const FIELDS_SINCE: {
3777
3852
  readonly AppsAccountsResetsResult: {
3778
3853
  readonly problem: "1.12";
3779
3854
  };
3855
+ readonly ChatRow: {
3856
+ readonly app_project: "1.13";
3857
+ readonly tokens: "1.13";
3858
+ readonly original_title: "1.14";
3859
+ readonly title_source: "1.14";
3860
+ readonly title_override: "1.14";
3861
+ };
3862
+ readonly AccountUsage: {
3863
+ readonly plan: "1.13";
3864
+ readonly credits: "1.13";
3865
+ };
3780
3866
  };
3781
3867
  type FieldsSincePath = keyof typeof FIELDS_SINCE;
3782
3868
  /**
@@ -3831,7 +3917,7 @@ declare function forPeer(op: OpName | null, part: "error", value: unknown, versi
3831
3917
  declare const VERSIONED_RESULT_OPS: readonly OpName[];
3832
3918
 
3833
3919
  /** SHA-256 of generated/desktop-protocol.schema.json: the contract both sides of a service connection were built from. */
3834
- declare const CONTRACT_SHA256: "179024ee4b3dc7123af1db44f8ce0fb9da7b392eed30a2a2b5bb312da3522bb0";
3920
+ declare const CONTRACT_SHA256: "274e5bac7ae2a9b7a8027a6c356f54654cd1ed91cf2363711a21ff821a33a676";
3835
3921
 
3836
3922
  /**
3837
3923
  * The local tool catalog (SPEC §10): every tool a platform agent calls on a person's computer, the
@@ -3958,4 +4044,4 @@ declare function buildToolStatus(files: readonly unknown[], opts: {
3958
4044
  /** The committed text form. Columns: per platform, the three levels (P = programmatic, R = protocol, C = chat). */
3959
4045
  declare function renderToolStatusMarkdown(status: ToolStatus): string;
3960
4046
 
3961
- export { AbsPath, AccountReset, AccountUsage, AppFeatureStatus, AppInfo, AppKey, AppProfile, AppProfileId, AppProfileLocator, AppSupport, AppUsageReading, AppWindowInfo, AppsAccountsResetsParams, AppsAccountsResetsResult, AppsAccountsUsageParams, AppsAccountsUsageResult, AppsChatsChangedEvent, AppsChatsColdParams, AppsChatsColdResult, AppsChatsListParams, AppsChatsListResult, AppsChatsOpenParams, AppsChatsPlaceParams, AppsChatsPlaceResult, AppsChatsStarParams, AppsChatsStarResult, AppsChatsWatchParams, AppsChatsWatchResult, AppsChatsWatchStateEvent, AppsListParams, AppsListResult, AppsOpenParams, AppsOpenResult, AppsProfilesListParams, AppsProfilesListResult, AppsProfilesRemoveParams, AppsProfilesRemoveResult, AppsProfilesSaveParams, AppsProfilesSaveResult, AppsProjectsCopyParams, AppsProjectsCopyResult, AppsProjectsCreateParams, AppsProjectsCreateResult, AppsProjectsFileManyParams, AppsProjectsFileManyResult, AppsProjectsFileParams, AppsProjectsFileResult, AppsProjectsImportPinsParams, AppsProjectsImportPinsResult, AppsProjectsMoveParams, AppsProjectsMoveResult, AppsProjectsUnfileParams, AppsProjectsUnfileResult, AppsProjectsUpdateParams, AppsProjectsUpdateResult, AppsSpendParams, AppsSpendResult, AppsSyncRunParams, AppsSyncStatusParams, AppsSyncStatusResult, AppsWindowActionResult, AppsWindowsAddParams, AppsWindowsListParams, AppsWindowsListResult, AppsWindowsOpenParams, AppsWindowsProcessesParams, AppsWindowsProcessesResult, AppsWindowsRefreshUsageParams, AppsWindowsReloadParams, AppsWindowsRestartParams, AppsWindowsSaveNamesParams, AudioDevice, AudioDevicesParams, AudioDevicesResult, AudioPlayParams, AudioPlayResult, AudioRecordParams, AudioRecordResult, CONTRACT_SHA256, type CatalogTool, type CellState, ChatFamily, ChatHidden, ChatId, ChatLastUse, ChatPin, ChatPlace, ChatProject, ChatProjectId, ChatRow, ChatRunning, ChatWindow, ClipboardReadParams, ClipboardReadResult, ClipboardWriteParams, ClipboardWriteResult, CodingHistoryBlocked, CodingHistoryFailure, CodingHistoryImportMissingParams, CodingHistoryImportMissingResult, CodingHistoryProgressEvent, CodingHistoryRun, CodingHistoryStep, CodingImportNextParams, CodingPlanMissingParams, CodingServiceCredentials, CodingServiceProgress, ColdChat, ContractHash, CoreToServiceMsg, DEFAULT_MAX_FRAME_PAYLOAD_BYTES, DEFAULT_MAX_MESSAGE_BYTES, DEFAULT_WINDOW_BYTES, DeviceId, EXCLUDED_TOOLS, ExecCwdEvent, ExecExitedEvent, ExecJobId, ExecJobInfo, ExecJobListParams, ExecJobListResult, ExecJobOutputParams, ExecJobOutputResult, ExecJobStartParams, ExecJobStartResult, ExecJobStopParams, ExecJobStopResult, ExecListParams, ExecListResult, ExecPtyKillParams, ExecPtyKillResult, ExecPtyResizeParams, ExecPtyResizeResult, ExecPtySignalParams, ExecPtySignalResult, ExecPtyStartParams, ExecPtyStartResult, ExecPtyWriteParams, ExecPtyWriteResult, ExecRunParams, ExecRunResult, ExecTitleEvent, FIELDS_SINCE, type FieldsSincePath, FrameHeader, FsChange, FsChangedEvent, FsDeleteParams, FsDeleteResult, FsEncoding, FsEntry, FsKind, FsListParams, FsListResult, FsMkdirParams, FsMkdirResult, FsMoveParams, FsMoveResult, FsPatchEditApplied, FsPatchParams, FsPatchResult, FsReadParams, FsReadResult, FsReadStreamParams, FsReadStreamResult, FsSearchContentParams, FsSearchContentResult, FsSearchPathsParams, FsSearchPathsResult, FsStatParams, FsStatResult, FsWatchEventsParams, FsWatchEventsResult, FsWatchId, FsWatchParams, FsWatchResult, FsWatchStartParams, FsWatchStartResult, FsWatchStopParams, FsWatchStopResult, FsWriteParams, FsWriteResult, InputHotkeyParams, InputHotkeyResult, InputKey, InputMouseClickParams, InputMouseClickResult, InputMouseMoveParams, InputMouseMoveResult, InputPoint, InputTypeTextParams, InputTypeTextResult, LEGACY_ACTIONS, LEGACY_DISPATCHERS, type LegacyDisposition, NULL_SINCE, OpName, OsPermissionName, PROTOCOL_MAJOR, PROTOCOL_MINOR, PROTOCOL_VERSION, PowerPreventSleepParams, PowerPreventSleepResult, PowerStatusParams, PowerStatusResult, ProcInfo, ProcKillParams, ProcKillResult, ProcListParams, ProcListResult, ProcPort, ProcPortsParams, ProcPortsResult, ProcSort, ProtocolVersion, PtyInfo, REASONS_SINCE, RELAY_CALL_HELLO_ID, RELAY_CALL_REQUEST_ID, RELAY_CALL_VERSION_HEADER, RelayAuthExpiringEvent, RelayCallEnvelope, RelayCallHello, RelayCallRequest, RelayCallResponse, RelayDeviceStatusEvent, RelayHopConnectionEnd, RelayHopEnvelopeHeader, RelayStatusResponse, RequestId, ResourceId, ResourceInfo, ResourcesDisk, ResourcesSnapshotParams, ResourcesSnapshotResult, SERVICE_MAX_FRAME_BYTES, ScreenCaptureParams, ScreenCaptureResult, ScreenDisplay, ScreenListParams, ScreenListResult, ServiceCancel, ServiceErrorMsg, ServiceHello, ServiceName, ServicePing, ServicePong, ServiceProgressMsg, ServiceRequest, ServiceResponse, ServiceShutdown, ServiceToCoreMsg, ServiceToken, ServiceWelcome, SessionAttachParams, SessionAttachResult, SessionControlChangedEvent, SessionDetachParams, SessionDetachResult, SessionListParams, SessionListResult, SessionReleaseParams, SessionReleaseResult, Signal, SpendAccount, SpendChat, SpendHelper, SpendIdle, SpendIdleScope, SpendLive, SpendModel, SpendScopes, SpendSplit, SpendStart, type StatusCell, type StatusEvidence, type StatusRow, SysinfoGetParams, SysinfoGetResult, SystemNotifyParams, SystemNotifyResult, SystemOpenPathParams, SystemOpenPathResult, SystemOpenUrlParams, SystemOpenUrlResult, TOOL_CATALOG, TOOL_GROUPS, TOOL_LEVELS, TOOL_PLATFORMS, type ToolGroup, type ToolGroupId, ToolLevel, ToolLevelResult, ToolName, ToolOutcome, type ToolPath, ToolPlatform, ToolResultsFile, type ToolState, type ToolStatus, ToolTransport, VERSIONED_RESULT_OPS, WindowFocusParams, WindowFocusResult, WindowInfo, WindowListParams, WindowListResult, WindowMinimizeParams, WindowMinimizeResult, WindowMoveParams, WindowMoveResult, announcedVersion, buildToolStatus, builtOps, compareVersions, epochMs, forPeer, knows, negotiate, nonNegInt, renderToolStatusMarkdown, statusForPeer, u32, versionSubprotocol };
4047
+ export { AbsPath, AccountReset, AccountUsage, AppFeatureStatus, AppInfo, AppKey, AppProfile, AppProfileId, AppProfileLocator, AppSupport, AppUsageReading, AppWindowInfo, AppsAccountsResetsParams, AppsAccountsResetsResult, AppsAccountsUsageParams, AppsAccountsUsageResult, AppsChatsChangedEvent, AppsChatsColdParams, AppsChatsColdResult, AppsChatsListParams, AppsChatsListResult, AppsChatsOpenParams, AppsChatsPlaceParams, AppsChatsPlaceResult, AppsChatsStarParams, AppsChatsStarResult, AppsChatsWatchParams, AppsChatsWatchResult, AppsChatsWatchStateEvent, AppsListParams, AppsListResult, AppsOpenParams, AppsOpenResult, AppsProfilesListParams, AppsProfilesListResult, AppsProfilesRemoveParams, AppsProfilesRemoveResult, AppsProfilesSaveParams, AppsProfilesSaveResult, AppsProjectsCopyParams, AppsProjectsCopyResult, AppsProjectsCreateParams, AppsProjectsCreateResult, AppsProjectsFileManyParams, AppsProjectsFileManyResult, AppsProjectsFileParams, AppsProjectsFileResult, AppsProjectsImportPinsParams, AppsProjectsImportPinsResult, AppsProjectsMoveParams, AppsProjectsMoveResult, AppsProjectsUnfileParams, AppsProjectsUnfileResult, AppsProjectsUpdateParams, AppsProjectsUpdateResult, AppsSpendParams, AppsSpendResult, AppsSyncRunParams, AppsSyncStatusParams, AppsSyncStatusResult, AppsWindowActionResult, AppsWindowsAddParams, AppsWindowsListParams, AppsWindowsListResult, AppsWindowsOpenParams, AppsWindowsProcessesParams, AppsWindowsProcessesResult, AppsWindowsRefreshUsageParams, AppsWindowsReloadParams, AppsWindowsRestartParams, AppsWindowsSaveNamesParams, AudioDevice, AudioDevicesParams, AudioDevicesResult, AudioPlayParams, AudioPlayResult, AudioRecordParams, AudioRecordResult, CONTRACT_SHA256, type CatalogTool, type CellState, ChatAppProject, ChatFamily, ChatHidden, ChatId, ChatLastUse, ChatPin, ChatPlace, ChatProject, ChatProjectId, ChatRow, ChatRunning, ChatWindow, ClipboardReadParams, ClipboardReadResult, ClipboardWriteParams, ClipboardWriteResult, CodingHistoryBlocked, CodingHistoryFailure, CodingHistoryImportMissingParams, CodingHistoryImportMissingResult, CodingHistoryProgressEvent, CodingHistoryRun, CodingHistoryStep, CodingImportNextParams, CodingPlanMissingParams, CodingServiceCredentials, CodingServiceProgress, ColdChat, ContractHash, CoreToServiceMsg, DEFAULT_MAX_FRAME_PAYLOAD_BYTES, DEFAULT_MAX_MESSAGE_BYTES, DEFAULT_WINDOW_BYTES, DeviceId, EXCLUDED_TOOLS, ExecCwdEvent, ExecExitedEvent, ExecJobId, ExecJobInfo, ExecJobListParams, ExecJobListResult, ExecJobOutputParams, ExecJobOutputResult, ExecJobStartParams, ExecJobStartResult, ExecJobStopParams, ExecJobStopResult, ExecListParams, ExecListResult, ExecPtyKillParams, ExecPtyKillResult, ExecPtyResizeParams, ExecPtyResizeResult, ExecPtySignalParams, ExecPtySignalResult, ExecPtyStartParams, ExecPtyStartResult, ExecPtyWriteParams, ExecPtyWriteResult, ExecRunParams, ExecRunResult, ExecTitleEvent, FIELDS_SINCE, type FieldsSincePath, FrameHeader, FsChange, FsChangedEvent, FsDeleteParams, FsDeleteResult, FsEncoding, FsEntry, FsKind, FsListParams, FsListResult, FsMkdirParams, FsMkdirResult, FsMoveParams, FsMoveResult, FsPatchEditApplied, FsPatchParams, FsPatchResult, FsReadParams, FsReadResult, FsReadStreamParams, FsReadStreamResult, FsSearchContentParams, FsSearchContentResult, FsSearchPathsParams, FsSearchPathsResult, FsStatParams, FsStatResult, FsWatchEventsParams, FsWatchEventsResult, FsWatchId, FsWatchParams, FsWatchResult, FsWatchStartParams, FsWatchStartResult, FsWatchStopParams, FsWatchStopResult, FsWriteParams, FsWriteResult, InputHotkeyParams, InputHotkeyResult, InputKey, InputMouseClickParams, InputMouseClickResult, InputMouseMoveParams, InputMouseMoveResult, InputPoint, InputTypeTextParams, InputTypeTextResult, LEGACY_ACTIONS, LEGACY_DISPATCHERS, type LegacyDisposition, NULL_SINCE, OpName, OsPermissionName, PROTOCOL_MAJOR, PROTOCOL_MINOR, PROTOCOL_VERSION, PowerPreventSleepParams, PowerPreventSleepResult, PowerStatusParams, PowerStatusResult, ProcInfo, ProcKillParams, ProcKillResult, ProcListParams, ProcListResult, ProcPort, ProcPortsParams, ProcPortsResult, ProcSort, ProtocolVersion, PtyInfo, REASONS_SINCE, RELAY_CALL_HELLO_ID, RELAY_CALL_REQUEST_ID, RELAY_CALL_VERSION_HEADER, RelayAuthExpiringEvent, RelayCallEnvelope, RelayCallHello, RelayCallRequest, RelayCallResponse, RelayDeviceStatusEvent, RelayHopConnectionEnd, RelayHopEnvelopeHeader, RelayStatusResponse, RequestId, ResourceId, ResourceInfo, ResourcesDisk, ResourcesSnapshotParams, ResourcesSnapshotResult, SERVICE_MAX_FRAME_BYTES, ScreenCaptureParams, ScreenCaptureResult, ScreenDisplay, ScreenListParams, ScreenListResult, ServiceCancel, ServiceErrorMsg, ServiceHello, ServiceName, ServicePing, ServicePong, ServiceProgressMsg, ServiceRequest, ServiceResponse, ServiceShutdown, ServiceToCoreMsg, ServiceToken, ServiceWelcome, SessionAttachParams, SessionAttachResult, SessionControlChangedEvent, SessionDetachParams, SessionDetachResult, SessionListParams, SessionListResult, SessionReleaseParams, SessionReleaseResult, Signal, SpendAccount, SpendChat, SpendHelper, SpendIdle, SpendIdleScope, SpendLive, SpendModel, SpendScopes, SpendSplit, SpendStart, type StatusCell, type StatusEvidence, type StatusRow, SysinfoGetParams, SysinfoGetResult, SystemNotifyParams, SystemNotifyResult, SystemOpenPathParams, SystemOpenPathResult, SystemOpenUrlParams, SystemOpenUrlResult, TOOL_CATALOG, TOOL_GROUPS, TOOL_LEVELS, TOOL_PLATFORMS, type ToolGroup, type ToolGroupId, ToolLevel, ToolLevelResult, ToolName, ToolOutcome, type ToolPath, ToolPlatform, ToolResultsFile, type ToolState, type ToolStatus, ToolTransport, VERSIONED_RESULT_OPS, WindowFocusParams, WindowFocusResult, WindowInfo, WindowListParams, WindowListResult, WindowMinimizeParams, WindowMinimizeResult, WindowMoveParams, WindowMoveResult, announcedVersion, buildToolStatus, builtOps, compareVersions, epochMs, forPeer, knows, negotiate, nonNegInt, renderToolStatusMarkdown, statusForPeer, u32, versionSubprotocol };
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { z } from 'zod';
2
- import { O as OpName } from './models-B2PuTc6a.js';
3
- export { B as BEARER_PREFIX, g as CLOSE_RULES, h as CancelMsg, j as ClientToCoreMsg, e as ClientType, k as CloseAction, l as CloseCode, m as CloseCodeValue, C as CloseOutcome, n as CloseRule, o as CoreToClientMsg, p as CreditMsg, D as DesktopProtocolError, d as EVENTS, q as EndMsg, E as EndReason, r as ErrorCode, s as ErrorCodeName, t as ErrorData, u as ErrorMsg, v as ErrorReason, w as ErrorReasonName, x as EventMsg, y as EventName, F as FsPatchEditFailure, H as HelloMsg, L as Limits, z as MlInstallPhase, A as MlInstallProgress, f as MlProgress, G as MlRuntimeState, I as MlServiceState, J as MlServiceStatus, K as MlStatusParams, N as MlStatusResult, P as ModelsInstallParams, Q as ModelsInstallResult, R as ModelsProgressEvent, U as ModelsStatusParams, V as ModelsStatusResult, X as ModelsTranscribeParams, M as ModelsTranscribeResult, Y as NAMED_SCHEMAS, Z as NamedSchemaId, c as OPS, _ as OpDescriptor, a as OpParams, b as OpResult, $ as OpSpec, a0 as PING_TEXT, a1 as PONG_TEXT, a2 as ProtocolErrorBody, a3 as RelayMsg, a4 as RequestMsg, a5 as ResponseMsg, a6 as SERVICES, a7 as SUBPROTOCOL, a8 as ServiceId, a9 as ServiceOpName, aa as ServiceOpSpec, ab as ServiceSpec, S as StreamMeta, ac as StreamMsg, ad as TranscriptSegment, T as TranscriptionModelId, ae as TranscriptionModelInfo, W as Welcome, af as closeRule, i as isDesktopProtocolError, ag as isTerminalClose } from './models-B2PuTc6a.js';
2
+ import { O as OpName } from './models-BcBSKFeq.js';
3
+ export { B as BEARER_PREFIX, g as CLOSE_RULES, h as CancelMsg, j as ClientToCoreMsg, e as ClientType, k as CloseAction, l as CloseCode, m as CloseCodeValue, C as CloseOutcome, n as CloseRule, o as CoreToClientMsg, p as CreditMsg, D as DesktopProtocolError, d as EVENTS, q as EndMsg, E as EndReason, r as ErrorCode, s as ErrorCodeName, t as ErrorData, u as ErrorMsg, v as ErrorReason, w as ErrorReasonName, x as EventMsg, y as EventName, F as FsPatchEditFailure, H as HelloMsg, L as Limits, z as MlInstallPhase, A as MlInstallProgress, f as MlProgress, G as MlRuntimeState, I as MlServiceState, J as MlServiceStatus, K as MlStatusParams, N as MlStatusResult, P as ModelsInstallParams, Q as ModelsInstallResult, R as ModelsProgressEvent, U as ModelsStatusParams, V as ModelsStatusResult, X as ModelsTranscribeParams, M as ModelsTranscribeResult, Y as NAMED_SCHEMAS, Z as NamedSchemaId, c as OPS, _ as OpDescriptor, a as OpParams, b as OpResult, $ as OpSpec, a0 as PING_TEXT, a1 as PONG_TEXT, a2 as ProtocolErrorBody, a3 as RelayMsg, a4 as RequestMsg, a5 as ResponseMsg, a6 as SERVICES, a7 as SUBPROTOCOL, a8 as ServiceId, a9 as ServiceOpName, aa as ServiceOpSpec, ab as ServiceSpec, S as StreamMeta, ac as StreamMsg, ad as TranscriptSegment, T as TranscriptionModelId, ae as TranscriptionModelInfo, W as Welcome, af as closeRule, i as isDesktopProtocolError, ag as isTerminalClose } from './models-BcBSKFeq.js';
4
4
  export { BROADCAST_CID, DecodedFrame, FRAME_HEADER_BYTES, FRAME_STRUCT_FORMAT, FRAME_VERSION, FrameChannel, FrameChannelValue, FrameFlag, assertFrameHeader, connectionEndFrame, decodeFrame, encodeFrame, hasFlag, isConnectionEnd, readCid, stampCid } from './frame.js';
5
5
 
6
6
  /** @ai-matrx/desktop-protocol — version and primitive schemas. Schema source: lint-enforced rules in scripts/check-schema-source.mjs. */
@@ -23,10 +23,11 @@ declare const PROTOCOL_MAJOR: 1;
23
23
  * 1.8 — `apps.chats.*` / `apps.projects.*`: a coding app's chats, windows, pins and projects, live.
24
24
  * 1.9 — chats placed in windows / held, several filed at once, projects renamed / archived / copied;
25
25
  * the list says when it is a saved copy being re-read (`updating`) and when it is not live.
26
+ * 1.14 — a chat row carries its original title, where it came from, and the person's rename.
26
27
  */
27
- declare const PROTOCOL_MINOR: 12;
28
+ declare const PROTOCOL_MINOR: 14;
28
29
  /** This package's version as the wire spells it ("major.minor"): hello, welcome, relay status. */
29
- declare const PROTOCOL_VERSION: "1.12";
30
+ declare const PROTOCOL_VERSION: "1.14";
30
31
  /** Internal building blocks — deliberately unnamed in $defs (inlined wherever used). */
31
32
  declare const u32: z.ZodInt;
32
33
  declare const nonNegInt: z.ZodInt;
@@ -1384,8 +1385,22 @@ declare const ChatRow: z.ZodObject<{
1384
1385
  cache_warm: z.ZodBoolean;
1385
1386
  cache_minutes_left: z.ZodInt;
1386
1387
  }, z.core.$strict>>;
1388
+ app_project: z.ZodOptional<z.ZodObject<{
1389
+ id: z.ZodString;
1390
+ name: z.ZodString;
1391
+ }, z.core.$strict>>;
1392
+ tokens: z.ZodOptional<z.ZodInt>;
1393
+ original_title: z.ZodOptional<z.ZodString>;
1394
+ title_source: z.ZodOptional<z.ZodString>;
1395
+ title_override: z.ZodOptional<z.ZodString>;
1387
1396
  }, z.core.$strict>;
1388
1397
  type ChatRow = z.output<typeof ChatRow>;
1398
+ /** 1.13: a project the app itself keeps (Codex's sidebar projects), never ours and never written. */
1399
+ declare const ChatAppProject: z.ZodObject<{
1400
+ id: z.ZodString;
1401
+ name: z.ZodString;
1402
+ }, z.core.$strict>;
1403
+ type ChatAppProject = z.output<typeof ChatAppProject>;
1389
1404
  /** 1.10: a chat's family: the conversation it was forked from, or the original it is a copy of. */
1390
1405
  declare const ChatFamily: z.ZodObject<{
1391
1406
  id: z.ZodString;
@@ -1451,6 +1466,14 @@ declare const AppsChatsListResult: z.ZodObject<{
1451
1466
  cache_warm: z.ZodBoolean;
1452
1467
  cache_minutes_left: z.ZodInt;
1453
1468
  }, z.core.$strict>>;
1469
+ app_project: z.ZodOptional<z.ZodObject<{
1470
+ id: z.ZodString;
1471
+ name: z.ZodString;
1472
+ }, z.core.$strict>>;
1473
+ tokens: z.ZodOptional<z.ZodInt>;
1474
+ original_title: z.ZodOptional<z.ZodString>;
1475
+ title_source: z.ZodOptional<z.ZodString>;
1476
+ title_override: z.ZodOptional<z.ZodString>;
1454
1477
  }, z.core.$strict>>;
1455
1478
  new_window_ms: z.ZodInt;
1456
1479
  updating: z.ZodOptional<z.ZodBoolean>;
@@ -1527,6 +1550,14 @@ declare const AppsProjectsFileResult: z.ZodObject<{
1527
1550
  cache_warm: z.ZodBoolean;
1528
1551
  cache_minutes_left: z.ZodInt;
1529
1552
  }, z.core.$strict>>;
1553
+ app_project: z.ZodOptional<z.ZodObject<{
1554
+ id: z.ZodString;
1555
+ name: z.ZodString;
1556
+ }, z.core.$strict>>;
1557
+ tokens: z.ZodOptional<z.ZodInt>;
1558
+ original_title: z.ZodOptional<z.ZodString>;
1559
+ title_source: z.ZodOptional<z.ZodString>;
1560
+ title_override: z.ZodOptional<z.ZodString>;
1530
1561
  }, z.core.$strict>;
1531
1562
  project: z.ZodObject<{
1532
1563
  id: z.ZodString;
@@ -1582,6 +1613,14 @@ declare const AppsProjectsUnfileResult: z.ZodObject<{
1582
1613
  cache_warm: z.ZodBoolean;
1583
1614
  cache_minutes_left: z.ZodInt;
1584
1615
  }, z.core.$strict>>;
1616
+ app_project: z.ZodOptional<z.ZodObject<{
1617
+ id: z.ZodString;
1618
+ name: z.ZodString;
1619
+ }, z.core.$strict>>;
1620
+ tokens: z.ZodOptional<z.ZodInt>;
1621
+ original_title: z.ZodOptional<z.ZodString>;
1622
+ title_source: z.ZodOptional<z.ZodString>;
1623
+ title_override: z.ZodOptional<z.ZodString>;
1585
1624
  }, z.core.$strict>;
1586
1625
  }, z.core.$strict>;
1587
1626
  type AppsProjectsUnfileResult = z.output<typeof AppsProjectsUnfileResult>;
@@ -1631,6 +1670,14 @@ declare const AppsChatsStarResult: z.ZodObject<{
1631
1670
  cache_warm: z.ZodBoolean;
1632
1671
  cache_minutes_left: z.ZodInt;
1633
1672
  }, z.core.$strict>>;
1673
+ app_project: z.ZodOptional<z.ZodObject<{
1674
+ id: z.ZodString;
1675
+ name: z.ZodString;
1676
+ }, z.core.$strict>>;
1677
+ tokens: z.ZodOptional<z.ZodInt>;
1678
+ original_title: z.ZodOptional<z.ZodString>;
1679
+ title_source: z.ZodOptional<z.ZodString>;
1680
+ title_override: z.ZodOptional<z.ZodString>;
1634
1681
  }, z.core.$strict>;
1635
1682
  }, z.core.$strict>;
1636
1683
  type AppsChatsStarResult = z.output<typeof AppsChatsStarResult>;
@@ -1695,6 +1742,14 @@ declare const AppsChatsPlaceResult: z.ZodObject<{
1695
1742
  cache_warm: z.ZodBoolean;
1696
1743
  cache_minutes_left: z.ZodInt;
1697
1744
  }, z.core.$strict>>;
1745
+ app_project: z.ZodOptional<z.ZodObject<{
1746
+ id: z.ZodString;
1747
+ name: z.ZodString;
1748
+ }, z.core.$strict>>;
1749
+ tokens: z.ZodOptional<z.ZodInt>;
1750
+ original_title: z.ZodOptional<z.ZodString>;
1751
+ title_source: z.ZodOptional<z.ZodString>;
1752
+ title_override: z.ZodOptional<z.ZodString>;
1698
1753
  }, z.core.$strict>;
1699
1754
  message: z.ZodString;
1700
1755
  }, z.core.$strict>;
@@ -1747,6 +1802,14 @@ declare const AppsProjectsFileManyResult: z.ZodObject<{
1747
1802
  cache_warm: z.ZodBoolean;
1748
1803
  cache_minutes_left: z.ZodInt;
1749
1804
  }, z.core.$strict>>;
1805
+ app_project: z.ZodOptional<z.ZodObject<{
1806
+ id: z.ZodString;
1807
+ name: z.ZodString;
1808
+ }, z.core.$strict>>;
1809
+ tokens: z.ZodOptional<z.ZodInt>;
1810
+ original_title: z.ZodOptional<z.ZodString>;
1811
+ title_source: z.ZodOptional<z.ZodString>;
1812
+ title_override: z.ZodOptional<z.ZodString>;
1750
1813
  }, z.core.$strict>>;
1751
1814
  project: z.ZodObject<{
1752
1815
  id: z.ZodString;
@@ -1829,6 +1892,8 @@ declare const AccountUsage: z.ZodObject<{
1829
1892
  live: z.ZodBoolean;
1830
1893
  weekly_resets_at_ms: z.ZodNullable<z.ZodInt>;
1831
1894
  weekly_reset_official: z.ZodNullable<z.ZodBoolean>;
1895
+ plan: z.ZodOptional<z.ZodString>;
1896
+ credits: z.ZodOptional<z.ZodString>;
1832
1897
  }, z.core.$strict>;
1833
1898
  type AccountUsage = z.output<typeof AccountUsage>;
1834
1899
  /** One window's account's next weekly reset and where the time came from. */
@@ -1885,6 +1950,8 @@ declare const AppsAccountsUsageResult: z.ZodObject<{
1885
1950
  live: z.ZodBoolean;
1886
1951
  weekly_resets_at_ms: z.ZodNullable<z.ZodInt>;
1887
1952
  weekly_reset_official: z.ZodNullable<z.ZodBoolean>;
1953
+ plan: z.ZodOptional<z.ZodString>;
1954
+ credits: z.ZodOptional<z.ZodString>;
1888
1955
  }, z.core.$strict>>;
1889
1956
  problem: z.ZodOptional<z.ZodString>;
1890
1957
  }, z.core.$strict>;
@@ -1989,6 +2056,14 @@ declare const AppsProjectsMoveResult: z.ZodObject<{
1989
2056
  cache_warm: z.ZodBoolean;
1990
2057
  cache_minutes_left: z.ZodInt;
1991
2058
  }, z.core.$strict>>;
2059
+ app_project: z.ZodOptional<z.ZodObject<{
2060
+ id: z.ZodString;
2061
+ name: z.ZodString;
2062
+ }, z.core.$strict>>;
2063
+ tokens: z.ZodOptional<z.ZodInt>;
2064
+ original_title: z.ZodOptional<z.ZodString>;
2065
+ title_source: z.ZodOptional<z.ZodString>;
2066
+ title_override: z.ZodOptional<z.ZodString>;
1992
2067
  }, z.core.$strict>;
1993
2068
  project: z.ZodObject<{
1994
2069
  id: z.ZodString;
@@ -3777,6 +3852,17 @@ declare const FIELDS_SINCE: {
3777
3852
  readonly AppsAccountsResetsResult: {
3778
3853
  readonly problem: "1.12";
3779
3854
  };
3855
+ readonly ChatRow: {
3856
+ readonly app_project: "1.13";
3857
+ readonly tokens: "1.13";
3858
+ readonly original_title: "1.14";
3859
+ readonly title_source: "1.14";
3860
+ readonly title_override: "1.14";
3861
+ };
3862
+ readonly AccountUsage: {
3863
+ readonly plan: "1.13";
3864
+ readonly credits: "1.13";
3865
+ };
3780
3866
  };
3781
3867
  type FieldsSincePath = keyof typeof FIELDS_SINCE;
3782
3868
  /**
@@ -3831,7 +3917,7 @@ declare function forPeer(op: OpName | null, part: "error", value: unknown, versi
3831
3917
  declare const VERSIONED_RESULT_OPS: readonly OpName[];
3832
3918
 
3833
3919
  /** SHA-256 of generated/desktop-protocol.schema.json: the contract both sides of a service connection were built from. */
3834
- declare const CONTRACT_SHA256: "179024ee4b3dc7123af1db44f8ce0fb9da7b392eed30a2a2b5bb312da3522bb0";
3920
+ declare const CONTRACT_SHA256: "274e5bac7ae2a9b7a8027a6c356f54654cd1ed91cf2363711a21ff821a33a676";
3835
3921
 
3836
3922
  /**
3837
3923
  * The local tool catalog (SPEC §10): every tool a platform agent calls on a person's computer, the
@@ -3958,4 +4044,4 @@ declare function buildToolStatus(files: readonly unknown[], opts: {
3958
4044
  /** The committed text form. Columns: per platform, the three levels (P = programmatic, R = protocol, C = chat). */
3959
4045
  declare function renderToolStatusMarkdown(status: ToolStatus): string;
3960
4046
 
3961
- export { AbsPath, AccountReset, AccountUsage, AppFeatureStatus, AppInfo, AppKey, AppProfile, AppProfileId, AppProfileLocator, AppSupport, AppUsageReading, AppWindowInfo, AppsAccountsResetsParams, AppsAccountsResetsResult, AppsAccountsUsageParams, AppsAccountsUsageResult, AppsChatsChangedEvent, AppsChatsColdParams, AppsChatsColdResult, AppsChatsListParams, AppsChatsListResult, AppsChatsOpenParams, AppsChatsPlaceParams, AppsChatsPlaceResult, AppsChatsStarParams, AppsChatsStarResult, AppsChatsWatchParams, AppsChatsWatchResult, AppsChatsWatchStateEvent, AppsListParams, AppsListResult, AppsOpenParams, AppsOpenResult, AppsProfilesListParams, AppsProfilesListResult, AppsProfilesRemoveParams, AppsProfilesRemoveResult, AppsProfilesSaveParams, AppsProfilesSaveResult, AppsProjectsCopyParams, AppsProjectsCopyResult, AppsProjectsCreateParams, AppsProjectsCreateResult, AppsProjectsFileManyParams, AppsProjectsFileManyResult, AppsProjectsFileParams, AppsProjectsFileResult, AppsProjectsImportPinsParams, AppsProjectsImportPinsResult, AppsProjectsMoveParams, AppsProjectsMoveResult, AppsProjectsUnfileParams, AppsProjectsUnfileResult, AppsProjectsUpdateParams, AppsProjectsUpdateResult, AppsSpendParams, AppsSpendResult, AppsSyncRunParams, AppsSyncStatusParams, AppsSyncStatusResult, AppsWindowActionResult, AppsWindowsAddParams, AppsWindowsListParams, AppsWindowsListResult, AppsWindowsOpenParams, AppsWindowsProcessesParams, AppsWindowsProcessesResult, AppsWindowsRefreshUsageParams, AppsWindowsReloadParams, AppsWindowsRestartParams, AppsWindowsSaveNamesParams, AudioDevice, AudioDevicesParams, AudioDevicesResult, AudioPlayParams, AudioPlayResult, AudioRecordParams, AudioRecordResult, CONTRACT_SHA256, type CatalogTool, type CellState, ChatFamily, ChatHidden, ChatId, ChatLastUse, ChatPin, ChatPlace, ChatProject, ChatProjectId, ChatRow, ChatRunning, ChatWindow, ClipboardReadParams, ClipboardReadResult, ClipboardWriteParams, ClipboardWriteResult, CodingHistoryBlocked, CodingHistoryFailure, CodingHistoryImportMissingParams, CodingHistoryImportMissingResult, CodingHistoryProgressEvent, CodingHistoryRun, CodingHistoryStep, CodingImportNextParams, CodingPlanMissingParams, CodingServiceCredentials, CodingServiceProgress, ColdChat, ContractHash, CoreToServiceMsg, DEFAULT_MAX_FRAME_PAYLOAD_BYTES, DEFAULT_MAX_MESSAGE_BYTES, DEFAULT_WINDOW_BYTES, DeviceId, EXCLUDED_TOOLS, ExecCwdEvent, ExecExitedEvent, ExecJobId, ExecJobInfo, ExecJobListParams, ExecJobListResult, ExecJobOutputParams, ExecJobOutputResult, ExecJobStartParams, ExecJobStartResult, ExecJobStopParams, ExecJobStopResult, ExecListParams, ExecListResult, ExecPtyKillParams, ExecPtyKillResult, ExecPtyResizeParams, ExecPtyResizeResult, ExecPtySignalParams, ExecPtySignalResult, ExecPtyStartParams, ExecPtyStartResult, ExecPtyWriteParams, ExecPtyWriteResult, ExecRunParams, ExecRunResult, ExecTitleEvent, FIELDS_SINCE, type FieldsSincePath, FrameHeader, FsChange, FsChangedEvent, FsDeleteParams, FsDeleteResult, FsEncoding, FsEntry, FsKind, FsListParams, FsListResult, FsMkdirParams, FsMkdirResult, FsMoveParams, FsMoveResult, FsPatchEditApplied, FsPatchParams, FsPatchResult, FsReadParams, FsReadResult, FsReadStreamParams, FsReadStreamResult, FsSearchContentParams, FsSearchContentResult, FsSearchPathsParams, FsSearchPathsResult, FsStatParams, FsStatResult, FsWatchEventsParams, FsWatchEventsResult, FsWatchId, FsWatchParams, FsWatchResult, FsWatchStartParams, FsWatchStartResult, FsWatchStopParams, FsWatchStopResult, FsWriteParams, FsWriteResult, InputHotkeyParams, InputHotkeyResult, InputKey, InputMouseClickParams, InputMouseClickResult, InputMouseMoveParams, InputMouseMoveResult, InputPoint, InputTypeTextParams, InputTypeTextResult, LEGACY_ACTIONS, LEGACY_DISPATCHERS, type LegacyDisposition, NULL_SINCE, OpName, OsPermissionName, PROTOCOL_MAJOR, PROTOCOL_MINOR, PROTOCOL_VERSION, PowerPreventSleepParams, PowerPreventSleepResult, PowerStatusParams, PowerStatusResult, ProcInfo, ProcKillParams, ProcKillResult, ProcListParams, ProcListResult, ProcPort, ProcPortsParams, ProcPortsResult, ProcSort, ProtocolVersion, PtyInfo, REASONS_SINCE, RELAY_CALL_HELLO_ID, RELAY_CALL_REQUEST_ID, RELAY_CALL_VERSION_HEADER, RelayAuthExpiringEvent, RelayCallEnvelope, RelayCallHello, RelayCallRequest, RelayCallResponse, RelayDeviceStatusEvent, RelayHopConnectionEnd, RelayHopEnvelopeHeader, RelayStatusResponse, RequestId, ResourceId, ResourceInfo, ResourcesDisk, ResourcesSnapshotParams, ResourcesSnapshotResult, SERVICE_MAX_FRAME_BYTES, ScreenCaptureParams, ScreenCaptureResult, ScreenDisplay, ScreenListParams, ScreenListResult, ServiceCancel, ServiceErrorMsg, ServiceHello, ServiceName, ServicePing, ServicePong, ServiceProgressMsg, ServiceRequest, ServiceResponse, ServiceShutdown, ServiceToCoreMsg, ServiceToken, ServiceWelcome, SessionAttachParams, SessionAttachResult, SessionControlChangedEvent, SessionDetachParams, SessionDetachResult, SessionListParams, SessionListResult, SessionReleaseParams, SessionReleaseResult, Signal, SpendAccount, SpendChat, SpendHelper, SpendIdle, SpendIdleScope, SpendLive, SpendModel, SpendScopes, SpendSplit, SpendStart, type StatusCell, type StatusEvidence, type StatusRow, SysinfoGetParams, SysinfoGetResult, SystemNotifyParams, SystemNotifyResult, SystemOpenPathParams, SystemOpenPathResult, SystemOpenUrlParams, SystemOpenUrlResult, TOOL_CATALOG, TOOL_GROUPS, TOOL_LEVELS, TOOL_PLATFORMS, type ToolGroup, type ToolGroupId, ToolLevel, ToolLevelResult, ToolName, ToolOutcome, type ToolPath, ToolPlatform, ToolResultsFile, type ToolState, type ToolStatus, ToolTransport, VERSIONED_RESULT_OPS, WindowFocusParams, WindowFocusResult, WindowInfo, WindowListParams, WindowListResult, WindowMinimizeParams, WindowMinimizeResult, WindowMoveParams, WindowMoveResult, announcedVersion, buildToolStatus, builtOps, compareVersions, epochMs, forPeer, knows, negotiate, nonNegInt, renderToolStatusMarkdown, statusForPeer, u32, versionSubprotocol };
4047
+ export { AbsPath, AccountReset, AccountUsage, AppFeatureStatus, AppInfo, AppKey, AppProfile, AppProfileId, AppProfileLocator, AppSupport, AppUsageReading, AppWindowInfo, AppsAccountsResetsParams, AppsAccountsResetsResult, AppsAccountsUsageParams, AppsAccountsUsageResult, AppsChatsChangedEvent, AppsChatsColdParams, AppsChatsColdResult, AppsChatsListParams, AppsChatsListResult, AppsChatsOpenParams, AppsChatsPlaceParams, AppsChatsPlaceResult, AppsChatsStarParams, AppsChatsStarResult, AppsChatsWatchParams, AppsChatsWatchResult, AppsChatsWatchStateEvent, AppsListParams, AppsListResult, AppsOpenParams, AppsOpenResult, AppsProfilesListParams, AppsProfilesListResult, AppsProfilesRemoveParams, AppsProfilesRemoveResult, AppsProfilesSaveParams, AppsProfilesSaveResult, AppsProjectsCopyParams, AppsProjectsCopyResult, AppsProjectsCreateParams, AppsProjectsCreateResult, AppsProjectsFileManyParams, AppsProjectsFileManyResult, AppsProjectsFileParams, AppsProjectsFileResult, AppsProjectsImportPinsParams, AppsProjectsImportPinsResult, AppsProjectsMoveParams, AppsProjectsMoveResult, AppsProjectsUnfileParams, AppsProjectsUnfileResult, AppsProjectsUpdateParams, AppsProjectsUpdateResult, AppsSpendParams, AppsSpendResult, AppsSyncRunParams, AppsSyncStatusParams, AppsSyncStatusResult, AppsWindowActionResult, AppsWindowsAddParams, AppsWindowsListParams, AppsWindowsListResult, AppsWindowsOpenParams, AppsWindowsProcessesParams, AppsWindowsProcessesResult, AppsWindowsRefreshUsageParams, AppsWindowsReloadParams, AppsWindowsRestartParams, AppsWindowsSaveNamesParams, AudioDevice, AudioDevicesParams, AudioDevicesResult, AudioPlayParams, AudioPlayResult, AudioRecordParams, AudioRecordResult, CONTRACT_SHA256, type CatalogTool, type CellState, ChatAppProject, ChatFamily, ChatHidden, ChatId, ChatLastUse, ChatPin, ChatPlace, ChatProject, ChatProjectId, ChatRow, ChatRunning, ChatWindow, ClipboardReadParams, ClipboardReadResult, ClipboardWriteParams, ClipboardWriteResult, CodingHistoryBlocked, CodingHistoryFailure, CodingHistoryImportMissingParams, CodingHistoryImportMissingResult, CodingHistoryProgressEvent, CodingHistoryRun, CodingHistoryStep, CodingImportNextParams, CodingPlanMissingParams, CodingServiceCredentials, CodingServiceProgress, ColdChat, ContractHash, CoreToServiceMsg, DEFAULT_MAX_FRAME_PAYLOAD_BYTES, DEFAULT_MAX_MESSAGE_BYTES, DEFAULT_WINDOW_BYTES, DeviceId, EXCLUDED_TOOLS, ExecCwdEvent, ExecExitedEvent, ExecJobId, ExecJobInfo, ExecJobListParams, ExecJobListResult, ExecJobOutputParams, ExecJobOutputResult, ExecJobStartParams, ExecJobStartResult, ExecJobStopParams, ExecJobStopResult, ExecListParams, ExecListResult, ExecPtyKillParams, ExecPtyKillResult, ExecPtyResizeParams, ExecPtyResizeResult, ExecPtySignalParams, ExecPtySignalResult, ExecPtyStartParams, ExecPtyStartResult, ExecPtyWriteParams, ExecPtyWriteResult, ExecRunParams, ExecRunResult, ExecTitleEvent, FIELDS_SINCE, type FieldsSincePath, FrameHeader, FsChange, FsChangedEvent, FsDeleteParams, FsDeleteResult, FsEncoding, FsEntry, FsKind, FsListParams, FsListResult, FsMkdirParams, FsMkdirResult, FsMoveParams, FsMoveResult, FsPatchEditApplied, FsPatchParams, FsPatchResult, FsReadParams, FsReadResult, FsReadStreamParams, FsReadStreamResult, FsSearchContentParams, FsSearchContentResult, FsSearchPathsParams, FsSearchPathsResult, FsStatParams, FsStatResult, FsWatchEventsParams, FsWatchEventsResult, FsWatchId, FsWatchParams, FsWatchResult, FsWatchStartParams, FsWatchStartResult, FsWatchStopParams, FsWatchStopResult, FsWriteParams, FsWriteResult, InputHotkeyParams, InputHotkeyResult, InputKey, InputMouseClickParams, InputMouseClickResult, InputMouseMoveParams, InputMouseMoveResult, InputPoint, InputTypeTextParams, InputTypeTextResult, LEGACY_ACTIONS, LEGACY_DISPATCHERS, type LegacyDisposition, NULL_SINCE, OpName, OsPermissionName, PROTOCOL_MAJOR, PROTOCOL_MINOR, PROTOCOL_VERSION, PowerPreventSleepParams, PowerPreventSleepResult, PowerStatusParams, PowerStatusResult, ProcInfo, ProcKillParams, ProcKillResult, ProcListParams, ProcListResult, ProcPort, ProcPortsParams, ProcPortsResult, ProcSort, ProtocolVersion, PtyInfo, REASONS_SINCE, RELAY_CALL_HELLO_ID, RELAY_CALL_REQUEST_ID, RELAY_CALL_VERSION_HEADER, RelayAuthExpiringEvent, RelayCallEnvelope, RelayCallHello, RelayCallRequest, RelayCallResponse, RelayDeviceStatusEvent, RelayHopConnectionEnd, RelayHopEnvelopeHeader, RelayStatusResponse, RequestId, ResourceId, ResourceInfo, ResourcesDisk, ResourcesSnapshotParams, ResourcesSnapshotResult, SERVICE_MAX_FRAME_BYTES, ScreenCaptureParams, ScreenCaptureResult, ScreenDisplay, ScreenListParams, ScreenListResult, ServiceCancel, ServiceErrorMsg, ServiceHello, ServiceName, ServicePing, ServicePong, ServiceProgressMsg, ServiceRequest, ServiceResponse, ServiceShutdown, ServiceToCoreMsg, ServiceToken, ServiceWelcome, SessionAttachParams, SessionAttachResult, SessionControlChangedEvent, SessionDetachParams, SessionDetachResult, SessionListParams, SessionListResult, SessionReleaseParams, SessionReleaseResult, Signal, SpendAccount, SpendChat, SpendHelper, SpendIdle, SpendIdleScope, SpendLive, SpendModel, SpendScopes, SpendSplit, SpendStart, type StatusCell, type StatusEvidence, type StatusRow, SysinfoGetParams, SysinfoGetResult, SystemNotifyParams, SystemNotifyResult, SystemOpenPathParams, SystemOpenPathResult, SystemOpenUrlParams, SystemOpenUrlResult, TOOL_CATALOG, TOOL_GROUPS, TOOL_LEVELS, TOOL_PLATFORMS, type ToolGroup, type ToolGroupId, ToolLevel, ToolLevelResult, ToolName, ToolOutcome, type ToolPath, ToolPlatform, ToolResultsFile, type ToolState, type ToolStatus, ToolTransport, VERSIONED_RESULT_OPS, WindowFocusParams, WindowFocusResult, WindowInfo, WindowListParams, WindowListResult, WindowMinimizeParams, WindowMinimizeResult, WindowMoveParams, WindowMoveResult, announcedVersion, buildToolStatus, builtOps, compareVersions, epochMs, forPeer, knows, negotiate, nonNegInt, renderToolStatusMarkdown, statusForPeer, u32, versionSubprotocol };
package/dist/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  // src/schema/primitives.ts
2
2
  import { z } from "zod";
3
3
  var PROTOCOL_MAJOR = 1;
4
- var PROTOCOL_MINOR = 12;
4
+ var PROTOCOL_MINOR = 14;
5
5
  var PROTOCOL_VERSION = `${PROTOCOL_MAJOR}.${PROTOCOL_MINOR}`;
6
6
  var ProtocolVersion = z.string().regex(/^[1-9][0-9]{0,2}\.[0-9]{1,3}$/);
7
7
  var RequestId = z.string().min(1).max(64).regex(/^[A-Za-z0-9_-]+$/);
@@ -936,6 +936,10 @@ var ChatLastUse = z12.strictObject({
936
936
  cache_warm: z12.boolean(),
937
937
  cache_minutes_left: nonNegInt
938
938
  });
939
+ var ChatAppProject = z12.strictObject({
940
+ id: z12.string().min(1).max(200),
941
+ name: z12.string().max(200)
942
+ });
939
943
  var ChatRow = z12.strictObject({
940
944
  id: ChatId,
941
945
  /** The short id people see (the listing's first 8 characters). */
@@ -962,7 +966,20 @@ var ChatRow = z12.strictObject({
962
966
  /** Created recently and in no project: offered for filing. */
963
967
  new_unfiled: z12.boolean(),
964
968
  warnings: z12.array(z12.string().max(400)).max(20),
965
- last_use: ChatLastUse.nullable()
969
+ last_use: ChatLastUse.nullable(),
970
+ /** 1.13: the app's own project the chat is grouped under in the app (Codex), read only; absent = none or not an app that groups. */
971
+ app_project: ChatAppProject.optional(),
972
+ /** 1.13: tokens the conversation has used, when the app records it (Codex); absent when not recorded; prices are not on disk. */
973
+ tokens: nonNegInt.optional(),
974
+ /**
975
+ * 1.14: the chat's own title before the person's rename (the one title rule, `@ai-matrx/coding-sessions/sessions`);
976
+ * `title` is what to show (`title_override` when set, else this).
977
+ */
978
+ original_title: z12.string().max(1e3).optional(),
979
+ /** 1.14: where `original_title` came from (app record, remembered, custom-title, ai-title, agent-name, summary, first-prompt, last-prompt). */
980
+ title_source: z12.string().min(1).max(40).optional(),
981
+ /** 1.14: the person's rename inside Matrx (Coding Sessions), applied once by the row builder; absent = none. */
982
+ title_override: z12.string().min(1).max(300).optional()
966
983
  });
967
984
  var ChatFamily = z12.strictObject({
968
985
  id: ChatId,
@@ -1085,7 +1102,11 @@ var AccountUsage = z13.strictObject({
1085
1102
  /** The next weekly reset, when known. */
1086
1103
  weekly_resets_at_ms: epochMs.nullable(),
1087
1104
  /** That reset time is Claude's own (its reading, or a reset seen in its usage history). */
1088
- weekly_reset_official: z13.boolean().nullable()
1105
+ weekly_reset_official: z13.boolean().nullable(),
1106
+ /** 1.13: the account's plan as the app names it (Codex: "pro", "prolite"), when recorded. */
1107
+ plan: z13.string().max(80).optional(),
1108
+ /** 1.13: the account's credit balance as the app records it (Codex), when recorded. */
1109
+ credits: z13.string().max(40).optional()
1089
1110
  });
1090
1111
  var AccountReset = z13.strictObject({
1091
1112
  window: ChatPlace,
@@ -2196,6 +2217,7 @@ var NAMED_SCHEMAS = {
2196
2217
  ChatRunning,
2197
2218
  ChatHidden,
2198
2219
  ChatLastUse,
2220
+ ChatAppProject,
2199
2221
  ChatRow,
2200
2222
  AppsChatsListParams,
2201
2223
  AppsChatsListResult,
@@ -2272,7 +2294,9 @@ var FIELDS_SINCE = {
2272
2294
  WindowInfo: { app: "1.7", pid: "1.7" },
2273
2295
  AppsChatsListResult: { updating: "1.9", live: "1.9", families: "1.10" },
2274
2296
  AppsAccountsUsageResult: { problem: "1.12" },
2275
- AppsAccountsResetsResult: { problem: "1.12" }
2297
+ AppsAccountsResetsResult: { problem: "1.12" },
2298
+ ChatRow: { app_project: "1.13", tokens: "1.13", original_title: "1.14", title_source: "1.14", title_override: "1.14" },
2299
+ AccountUsage: { plan: "1.13", credits: "1.13" }
2276
2300
  };
2277
2301
  var NULL_SINCE = {
2278
2302
  "RelayDeviceStatusEvent.since_ms": { since: "1.1", olderPeersGet: 0 }
@@ -2331,6 +2355,33 @@ var RESULT_PATH = /* @__PURE__ */ new Map([
2331
2355
  ["apps.accounts.usage", "AppsAccountsUsageResult"],
2332
2356
  ["apps.accounts.resets", "AppsAccountsResetsResult"]
2333
2357
  ]);
2358
+ var NESTED_RESULTS = /* @__PURE__ */ new Map([
2359
+ ["apps.chats.list", [["chats", "ChatRow"]]],
2360
+ ["apps.projects.file", [["chat", "ChatRow"]]],
2361
+ ["apps.projects.file_many", [["chats", "ChatRow"]]],
2362
+ ["apps.projects.unfile", [["chat", "ChatRow"]]],
2363
+ ["apps.projects.move", [["chat", "ChatRow"]]],
2364
+ ["apps.chats.star", [["chat", "ChatRow"]]],
2365
+ ["apps.chats.place", [["chat", "ChatRow"]]],
2366
+ ["apps.accounts.usage", [["accounts", "AccountUsage"]]]
2367
+ ]);
2368
+ function stripNested(value, nested, version) {
2369
+ if (value === null || typeof value !== "object" || Array.isArray(value)) return value;
2370
+ let body = value;
2371
+ for (const [key, path] of nested) {
2372
+ const inner = body[key];
2373
+ if (inner === void 0 || inner === null) continue;
2374
+ const fields = FIELDS_SINCE[path];
2375
+ if (Array.isArray(inner)) {
2376
+ const next = inner.map((x) => strip(x, fields, version));
2377
+ if (next.some((x, i) => x !== inner[i])) body = { ...body, [key]: next };
2378
+ } else {
2379
+ const next = strip(inner, fields, version);
2380
+ if (next !== inner) body = { ...body, [key]: next };
2381
+ }
2382
+ }
2383
+ return body;
2384
+ }
2334
2385
  var WINDOW_RESULTS = /* @__PURE__ */ new Map([
2335
2386
  ["window.list", "windows"],
2336
2387
  ["window.focus", "window"],
@@ -2354,7 +2405,9 @@ function forPeer(op, part, value, version) {
2354
2405
  const windowKey = op ? WINDOW_RESULTS.get(op) : void 0;
2355
2406
  if (windowKey) return stripWindows(value, windowKey, version);
2356
2407
  const path = op ? RESULT_PATH.get(op) : void 0;
2357
- return path ? strip(value, FIELDS_SINCE[path], version) : value;
2408
+ const top = path ? strip(value, FIELDS_SINCE[path], version) : value;
2409
+ const nested = op ? NESTED_RESULTS.get(op) : void 0;
2410
+ return nested ? stripNested(top, nested, version) : top;
2358
2411
  }
2359
2412
  if (value === null || typeof value !== "object") return value;
2360
2413
  const body = value;
@@ -2368,10 +2421,10 @@ function forPeer(op, part, value, version) {
2368
2421
  }
2369
2422
  return data === body.data ? value : { ...body, data };
2370
2423
  }
2371
- var VERSIONED_RESULT_OPS = [...RESULT_PATH.keys(), ...WINDOW_RESULTS.keys()];
2424
+ var VERSIONED_RESULT_OPS = [.../* @__PURE__ */ new Set([...RESULT_PATH.keys(), ...WINDOW_RESULTS.keys(), ...NESTED_RESULTS.keys()])];
2372
2425
 
2373
2426
  // src/contract.ts
2374
- var CONTRACT_SHA256 = "179024ee4b3dc7123af1db44f8ce0fb9da7b392eed30a2a2b5bb312da3522bb0";
2427
+ var CONTRACT_SHA256 = "274e5bac7ae2a9b7a8027a6c356f54654cd1ed91cf2363711a21ff821a33a676";
2375
2428
 
2376
2429
  // src/close-policy.ts
2377
2430
  var CLOSE_RULES = {
@@ -2795,6 +2848,7 @@ export {
2795
2848
  CLOSE_RULES,
2796
2849
  CONTRACT_SHA256,
2797
2850
  CancelMsg,
2851
+ ChatAppProject,
2798
2852
  ChatFamily,
2799
2853
  ChatHidden,
2800
2854
  ChatId,