@agent-marshal/marshal-prime-agent 0.48.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 +73 -0
- package/package.json +48 -0
- package/src/daemon.ts +358 -0
- package/src/entities.ts +197 -0
- package/src/generated/AckMessages.ts +16 -0
- package/src/generated/AckMessagesArgs.ts +16 -0
- package/src/generated/AckMessagesResult.ts +12 -0
- package/src/generated/AutoSource.ts +9 -0
- package/src/generated/BroadcastMessage.ts +10 -0
- package/src/generated/BroadcastMessageArgs.ts +10 -0
- package/src/generated/BroadcastMessageResult.ts +25 -0
- package/src/generated/CancelSubscription.ts +6 -0
- package/src/generated/ChildEntities.ts +6 -0
- package/src/generated/ChildEntitiesAllTime.ts +6 -0
- package/src/generated/ClearClientWindbackTime.ts +7 -0
- package/src/generated/ClearClientWindbackTimeArgs.ts +3 -0
- package/src/generated/Client.ts +14 -0
- package/src/generated/ClientCount.ts +3 -0
- package/src/generated/ClientId.ts +3 -0
- package/src/generated/ClientStatus.ts +7 -0
- package/src/generated/ClientStatusOutput.ts +3 -0
- package/src/generated/CommandError.ts +3 -0
- package/src/generated/CommandResponse.ts +4 -0
- package/src/generated/CountAllClients.ts +3 -0
- package/src/generated/CountAllMessageReads.ts +3 -0
- package/src/generated/CountAllMessages.ts +3 -0
- package/src/generated/CountAllRoomMembers.ts +3 -0
- package/src/generated/CountAllRooms.ts +3 -0
- package/src/generated/CountAllServers.ts +3 -0
- package/src/generated/CountAllSessionNicknames.ts +3 -0
- package/src/generated/CountAllSessions.ts +3 -0
- package/src/generated/CountClients.ts +4 -0
- package/src/generated/CountMessageReads.ts +4 -0
- package/src/generated/CountMessages.ts +4 -0
- package/src/generated/CountRoomMembers.ts +4 -0
- package/src/generated/CountRooms.ts +4 -0
- package/src/generated/CountServers.ts +4 -0
- package/src/generated/CountSessionNicknames.ts +4 -0
- package/src/generated/CountSessions.ts +4 -0
- package/src/generated/DeleteClient.ts +7 -0
- package/src/generated/DeleteClientArgs.ts +4 -0
- package/src/generated/DeleteClientResult.ts +6 -0
- package/src/generated/DeleteClients.ts +7 -0
- package/src/generated/DeleteClientsArgs.ts +4 -0
- package/src/generated/DeleteClientsResult.ts +6 -0
- package/src/generated/DeleteMessage.ts +7 -0
- package/src/generated/DeleteMessageArgs.ts +4 -0
- package/src/generated/DeleteMessageRead.ts +7 -0
- package/src/generated/DeleteMessageReadArgs.ts +4 -0
- package/src/generated/DeleteMessageReadResult.ts +6 -0
- package/src/generated/DeleteMessageReads.ts +7 -0
- package/src/generated/DeleteMessageReadsArgs.ts +4 -0
- package/src/generated/DeleteMessageReadsResult.ts +6 -0
- package/src/generated/DeleteMessageResult.ts +6 -0
- package/src/generated/DeleteMessages.ts +7 -0
- package/src/generated/DeleteMessagesArgs.ts +4 -0
- package/src/generated/DeleteMessagesResult.ts +6 -0
- package/src/generated/DeleteRoom.ts +7 -0
- package/src/generated/DeleteRoomArgs.ts +4 -0
- package/src/generated/DeleteRoomMember.ts +7 -0
- package/src/generated/DeleteRoomMemberArgs.ts +4 -0
- package/src/generated/DeleteRoomMemberResult.ts +6 -0
- package/src/generated/DeleteRoomMembers.ts +7 -0
- package/src/generated/DeleteRoomMembersArgs.ts +4 -0
- package/src/generated/DeleteRoomMembersResult.ts +6 -0
- package/src/generated/DeleteRoomResult.ts +6 -0
- package/src/generated/DeleteRooms.ts +7 -0
- package/src/generated/DeleteRoomsArgs.ts +4 -0
- package/src/generated/DeleteRoomsResult.ts +6 -0
- package/src/generated/DeleteServer.ts +7 -0
- package/src/generated/DeleteServerArgs.ts +4 -0
- package/src/generated/DeleteServerResult.ts +6 -0
- package/src/generated/DeleteServers.ts +7 -0
- package/src/generated/DeleteServersArgs.ts +4 -0
- package/src/generated/DeleteServersResult.ts +6 -0
- package/src/generated/DeleteSession.ts +7 -0
- package/src/generated/DeleteSessionArgs.ts +4 -0
- package/src/generated/DeleteSessionNickname.ts +7 -0
- package/src/generated/DeleteSessionNicknameArgs.ts +4 -0
- package/src/generated/DeleteSessionNicknameResult.ts +6 -0
- package/src/generated/DeleteSessionNicknames.ts +7 -0
- package/src/generated/DeleteSessionNicknamesArgs.ts +4 -0
- package/src/generated/DeleteSessionNicknamesResult.ts +6 -0
- package/src/generated/DeleteSessionResult.ts +6 -0
- package/src/generated/DeleteSessions.ts +7 -0
- package/src/generated/DeleteSessionsArgs.ts +4 -0
- package/src/generated/DeleteSessionsResult.ts +6 -0
- package/src/generated/DeliveredRecipient.ts +4 -0
- package/src/generated/EntitySearch.ts +21 -0
- package/src/generated/EntitySearchResult.ts +10 -0
- package/src/generated/EntitySnapshotDifference.ts +6 -0
- package/src/generated/EntitySnapshotDifferenceData.ts +7 -0
- package/src/generated/EntityTreeExport.ts +27 -0
- package/src/generated/EventContainer.ts +7 -0
- package/src/generated/EventOptions.ts +11 -0
- package/src/generated/EventsForTransaction.ts +6 -0
- package/src/generated/ExportEntityTree.ts +24 -0
- package/src/generated/ExportedEntity.ts +15 -0
- package/src/generated/FailedRecipient.ts +4 -0
- package/src/generated/FullChildEntities.ts +6 -0
- package/src/generated/GetAllClients.ts +3 -0
- package/src/generated/GetAllMessageReads.ts +3 -0
- package/src/generated/GetAllMessages.ts +3 -0
- package/src/generated/GetAllRoomMembers.ts +3 -0
- package/src/generated/GetAllRooms.ts +3 -0
- package/src/generated/GetAllServers.ts +3 -0
- package/src/generated/GetAllSessionNicknames.ts +3 -0
- package/src/generated/GetAllSessions.ts +3 -0
- package/src/generated/GetClientById.ts +4 -0
- package/src/generated/GetClientsByIds.ts +4 -0
- package/src/generated/GetClientsByQuery.ts +4 -0
- package/src/generated/GetConnectedServer.ts +3 -0
- package/src/generated/GetItemsByTypeAndIds.ts +14 -0
- package/src/generated/GetMessageById.ts +4 -0
- package/src/generated/GetMessageReadById.ts +4 -0
- package/src/generated/GetMessageReadsByIds.ts +4 -0
- package/src/generated/GetMessageReadsByQuery.ts +4 -0
- package/src/generated/GetMessagesByIds.ts +4 -0
- package/src/generated/GetMessagesByQuery.ts +4 -0
- package/src/generated/GetPeerServers.ts +3 -0
- package/src/generated/GetPersistHealth.ts +8 -0
- package/src/generated/GetRoomById.ts +4 -0
- package/src/generated/GetRoomMemberById.ts +4 -0
- package/src/generated/GetRoomMembersByIds.ts +4 -0
- package/src/generated/GetRoomMembersByQuery.ts +4 -0
- package/src/generated/GetRoomsByIds.ts +4 -0
- package/src/generated/GetRoomsByQuery.ts +4 -0
- package/src/generated/GetServerById.ts +4 -0
- package/src/generated/GetServersByIds.ts +4 -0
- package/src/generated/GetServersByQuery.ts +4 -0
- package/src/generated/GetSessionById.ts +4 -0
- package/src/generated/GetSessionNicknameById.ts +4 -0
- package/src/generated/GetSessionNicknamesByIds.ts +4 -0
- package/src/generated/GetSessionNicknamesByQuery.ts +4 -0
- package/src/generated/GetSessionsByIds.ts +4 -0
- package/src/generated/GetSessionsByQuery.ts +4 -0
- package/src/generated/HostInfo.ts +21 -0
- package/src/generated/ImportItems.ts +19 -0
- package/src/generated/ImportItemsArgs.ts +13 -0
- package/src/generated/ItemStub.ts +7 -0
- package/src/generated/JoinRoom.ts +19 -0
- package/src/generated/JoinRoomArgs.ts +19 -0
- package/src/generated/JoinRoomResult.ts +14 -0
- package/src/generated/LeaveRoom.ts +14 -0
- package/src/generated/LeaveRoomArgs.ts +14 -0
- package/src/generated/LeaveRoomResult.ts +9 -0
- package/src/generated/LivePushStatus.ts +3 -0
- package/src/generated/LogLevel.ts +6 -0
- package/src/generated/Loggers.ts +6 -0
- package/src/generated/MEvent.ts +5 -0
- package/src/generated/MEventType.ts +3 -0
- package/src/generated/Message.ts +60 -0
- package/src/generated/MessageCount.ts +3 -0
- package/src/generated/MessageId.ts +3 -0
- package/src/generated/MessageRead.ts +10 -0
- package/src/generated/MessageReadCount.ts +3 -0
- package/src/generated/MessageReadId.ts +3 -0
- package/src/generated/MessageView.ts +12 -0
- package/src/generated/MykoMessage.ts +19 -0
- package/src/generated/NotifyChannel.ts +10 -0
- package/src/generated/NotifyChannelArgs.ts +4 -0
- package/src/generated/PartialClient.ts +14 -0
- package/src/generated/PartialMessage.ts +60 -0
- package/src/generated/PartialMessageRead.ts +10 -0
- package/src/generated/PartialRoom.ts +23 -0
- package/src/generated/PartialRoomMember.ts +13 -0
- package/src/generated/PartialServer.ts +4 -0
- package/src/generated/PartialSession.ts +130 -0
- package/src/generated/PartialSessionNickname.ts +9 -0
- package/src/generated/PeerAlive.ts +7 -0
- package/src/generated/PersistHealthStatus.ts +34 -0
- package/src/generated/PingData.ts +14 -0
- package/src/generated/QueryError.ts +3 -0
- package/src/generated/QueryWindow.ts +3 -0
- package/src/generated/QueryWindowUpdate.ts +4 -0
- package/src/generated/ReadMessages.ts +48 -0
- package/src/generated/ReadMessagesArgs.ts +48 -0
- package/src/generated/ReadMessagesResult.ts +9 -0
- package/src/generated/ReportError.ts +3 -0
- package/src/generated/ReportResponse.ts +4 -0
- package/src/generated/Room.ts +23 -0
- package/src/generated/RoomCount.ts +3 -0
- package/src/generated/RoomId.ts +3 -0
- package/src/generated/RoomKind.ts +9 -0
- package/src/generated/RoomMember.ts +13 -0
- package/src/generated/RoomMemberCount.ts +3 -0
- package/src/generated/RoomMemberId.ts +3 -0
- package/src/generated/SearchServer.ts +8 -0
- package/src/generated/SearchServerResult.ts +4 -0
- package/src/generated/SendMessage.ts +12 -0
- package/src/generated/SendMessageArgs.ts +12 -0
- package/src/generated/SendMessageResult.ts +33 -0
- package/src/generated/Server.ts +4 -0
- package/src/generated/ServerCount.ts +3 -0
- package/src/generated/ServerId.ts +3 -0
- package/src/generated/ServerLogLevel.ts +6 -0
- package/src/generated/ServerStats.ts +27 -0
- package/src/generated/ServerStatsOutput.ts +20 -0
- package/src/generated/Session.ts +130 -0
- package/src/generated/SessionCount.ts +3 -0
- package/src/generated/SessionId.ts +3 -0
- package/src/generated/SessionNickname.ts +9 -0
- package/src/generated/SessionNicknameCount.ts +3 -0
- package/src/generated/SessionNicknameId.ts +3 -0
- package/src/generated/SetClientWindbackTime.ts +11 -0
- package/src/generated/SetClientWindbackTimeArgs.ts +7 -0
- package/src/generated/SetLogLevel.ts +7 -0
- package/src/generated/SetLogLevelArgs.ts +4 -0
- package/src/generated/SetRoomDescription.ts +7 -0
- package/src/generated/SetRoomDescriptionArgs.ts +4 -0
- package/src/generated/SetRoomName.ts +7 -0
- package/src/generated/SetRoomNameArgs.ts +4 -0
- package/src/generated/SetSessionActivity.ts +7 -0
- package/src/generated/SetSessionActivityArgs.ts +4 -0
- package/src/generated/SetSessionCurrentTask.ts +7 -0
- package/src/generated/SetSessionCurrentTaskArgs.ts +4 -0
- package/src/generated/SetSessionGitBranch.ts +7 -0
- package/src/generated/SetSessionGitBranchArgs.ts +4 -0
- package/src/generated/SetSessionLastActivityAt.ts +7 -0
- package/src/generated/SetSessionLastActivityAtArgs.ts +4 -0
- package/src/generated/SetSessionLastTool.ts +7 -0
- package/src/generated/SetSessionLastToolArgs.ts +4 -0
- package/src/generated/SetSessionLastToolAt.ts +7 -0
- package/src/generated/SetSessionLastToolAtArgs.ts +4 -0
- package/src/generated/SetSessionSessionName.ts +7 -0
- package/src/generated/SetSessionSessionNameArgs.ts +4 -0
- package/src/generated/StartProfile.ts +10 -0
- package/src/generated/StartProfileArgs.ts +7 -0
- package/src/generated/StopProfile.ts +6 -0
- package/src/generated/StopProfileArgs.ts +3 -0
- package/src/generated/StopProfileOutput.ts +14 -0
- package/src/generated/ViewError.ts +3 -0
- package/src/generated/ViewWindowUpdate.ts +4 -0
- package/src/generated/WakeStatus.ts +3 -0
- package/src/generated/WindbackStatus.ts +3 -0
- package/src/generated/WindbackStatusOutput.ts +11 -0
- package/src/generated/WrappedCommand.ts +4 -0
- package/src/generated/WrappedItem.ts +7 -0
- package/src/generated/WrappedQuery.ts +5 -0
- package/src/generated/WrappedReport.ts +4 -0
- package/src/generated/WrappedView.ts +5 -0
- package/src/generated/index.ts +1060 -0
- package/src/generated/serde_json/JsonValue.ts +3 -0
- package/src/identity.ts +61 -0
- package/src/index.ts +589 -0
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { MessageId } from "./MessageId";
|
|
3
|
+
import type { RoomId } from "./RoomId";
|
|
4
|
+
import type { SessionId } from "./SessionId";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* A message in the bus. Polymorphic recipient — either a peer session
|
|
8
|
+
* (direct send) or a room (broadcast). Exactly one of `to_session_id`
|
|
9
|
+
* and `to_room_id` is set; serde defaults to `None` on the absent
|
|
10
|
+
* side so legacy direct-only payloads from before broadcast existed
|
|
11
|
+
* replay clean.
|
|
12
|
+
*
|
|
13
|
+
* Read state lives on the `MessageRead` join entity, not here, so a
|
|
14
|
+
* broadcast can have per-recipient acks without ambiguity.
|
|
15
|
+
*
|
|
16
|
+
* No denormalized display fields. Sender/recipient labels are computed
|
|
17
|
+
* at read time from the live Session row (and degrade to the session_id
|
|
18
|
+
* itself when the row is gone). Snapshotting nicknames at send time was
|
|
19
|
+
* the source of consistency drift after rename/disconnect; with
|
|
20
|
+
* session_id as the sole stored identity there is nothing to drift.
|
|
21
|
+
*/
|
|
22
|
+
export type Message = {
|
|
23
|
+
/**
|
|
24
|
+
* Sender's session id. NOT a `belongs_to(Session)` cascade: a sent
|
|
25
|
+
* message must survive the sender exiting so the recipient can still
|
|
26
|
+
* pull it. In the pull-via-hook model the recipient reads on its
|
|
27
|
+
* next turn — which can be after the sender's SessionEnd — so
|
|
28
|
+
* cascading on the sender would silently delete unread messages in
|
|
29
|
+
* that window. The message's lifetime is governed by the *recipient*
|
|
30
|
+
* instead (the `to_session_id` / `to_room_id` cascades below).
|
|
31
|
+
*/
|
|
32
|
+
fromSessionId: SessionId,
|
|
33
|
+
/**
|
|
34
|
+
* Direct recipient — set for 1:1 sends, `None` for broadcasts.
|
|
35
|
+
* Cascade-DELs the message when the recipient session is DEL'd.
|
|
36
|
+
*/
|
|
37
|
+
toSessionId?: SessionId | null,
|
|
38
|
+
/**
|
|
39
|
+
* Broadcast recipient — set for room sends, `None` for direct
|
|
40
|
+
* sends. Cascade-DELs when the room is DEL'd. (Auto-rooms like
|
|
41
|
+
* `everyone` and `host:*` are never DEL'd, so broadcasts to them
|
|
42
|
+
* effectively persist forever.)
|
|
43
|
+
*/
|
|
44
|
+
toRoomId?: RoomId | null,
|
|
45
|
+
/**
|
|
46
|
+
* When this direct message was addressed to a *human* — via their operator
|
|
47
|
+
* identity (the `op:`/`human:`/email tier of recipient resolution) rather
|
|
48
|
+
* than to one specific agent — this holds that operator string (e.g.
|
|
49
|
+
* `max@lucid.rocks`). The message is still routed to, and cascades on, the
|
|
50
|
+
* operator's most-active session via `to_session_id`; this marks it as
|
|
51
|
+
* human-addressed so the receiving agent surfaces it to its operator
|
|
52
|
+
* instead of treating it as ordinary peer chatter, and the UI console can
|
|
53
|
+
* toast it for that operator regardless of which agent it landed on. `None`
|
|
54
|
+
* for agent-to-agent mail. serde-default so pre-field payloads replay clean.
|
|
55
|
+
*/
|
|
56
|
+
toOperator?: string | null, body: string,
|
|
57
|
+
/**
|
|
58
|
+
* Wall-clock millis when the daemon accepted the message.
|
|
59
|
+
*/
|
|
60
|
+
sentAt: bigint, id: MessageId, };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { MessageId } from "./MessageId";
|
|
3
|
+
import type { MessageReadId } from "./MessageReadId";
|
|
4
|
+
import type { SessionId } from "./SessionId";
|
|
5
|
+
|
|
6
|
+
export type MessageRead = { messageId: MessageId, sessionId: SessionId,
|
|
7
|
+
/**
|
|
8
|
+
* Wall-clock millis when this session marked the message read.
|
|
9
|
+
*/
|
|
10
|
+
readAt: bigint, id: MessageReadId, };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { MessageId } from "./MessageId";
|
|
3
|
+
import type { RoomId } from "./RoomId";
|
|
4
|
+
import type { SessionId } from "./SessionId";
|
|
5
|
+
|
|
6
|
+
export type MessageView = { messageId: MessageId, fromSessionId: SessionId, toSessionId: SessionId | null, toRoomId: RoomId | null,
|
|
7
|
+
/**
|
|
8
|
+
* Set when the message was addressed to a human via their operator
|
|
9
|
+
* identity (see `Message::to_operator`) — the recipient agent surfaces
|
|
10
|
+
* these to its operator rather than treating them as peer chatter.
|
|
11
|
+
*/
|
|
12
|
+
toOperator?: string | null, body: string, sentAt: bigint, readByMe: boolean, };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { CancelSubscription } from "./CancelSubscription";
|
|
3
|
+
import type { CommandError } from "./CommandError";
|
|
4
|
+
import type { CommandResponse } from "./CommandResponse";
|
|
5
|
+
import type { MEvent } from "./MEvent";
|
|
6
|
+
import type { PingData } from "./PingData";
|
|
7
|
+
import type { QueryError } from "./QueryError";
|
|
8
|
+
import type { QueryWindowUpdate } from "./QueryWindowUpdate";
|
|
9
|
+
import type { ReportError } from "./ReportError";
|
|
10
|
+
import type { ReportResponse } from "./ReportResponse";
|
|
11
|
+
import type { ViewError } from "./ViewError";
|
|
12
|
+
import type { ViewWindowUpdate } from "./ViewWindowUpdate";
|
|
13
|
+
import type { WrappedCommand } from "./WrappedCommand";
|
|
14
|
+
import type { WrappedQuery } from "./WrappedQuery";
|
|
15
|
+
import type { WrappedReport } from "./WrappedReport";
|
|
16
|
+
import type { WrappedView } from "./WrappedView";
|
|
17
|
+
import type { JsonValue } from "./serde_json/JsonValue";
|
|
18
|
+
|
|
19
|
+
export type MykoMessage = { "event": "ws:m:query", "data": WrappedQuery } | { "event": "ws:m:query-response", "data": any } | { "event": "ws:m:query-cancel", "data": CancelSubscription } | { "event": "ws:m:query-window", "data": QueryWindowUpdate } | { "event": "ws:m:view", "data": WrappedView } | { "event": "ws:m:view-response", "data": any } | { "event": "ws:m:view-cancel", "data": CancelSubscription } | { "event": "ws:m:view-window", "data": ViewWindowUpdate } | { "event": "ws:m:report", "data": WrappedReport } | { "event": "ws:m:report-response", "data": ReportResponse } | { "event": "ws:m:report-cancel", "data": CancelSubscription } | { "event": "ws:m:report-error", "data": ReportError } | { "event": "ws:m:query-error", "data": QueryError } | { "event": "ws:m:view-error", "data": ViewError } | { "event": "ws:m:event", "data": MEvent } | { "event": "ws:m:event-batch", "data": Array<MEvent> } | { "event": "ws:m:command", "data": WrappedCommand } | { "event": "ws:m:command-response", "data": CommandResponse } | { "event": "ws:m:command-error", "data": CommandError } | { "event": "ws:m:ping", "data": PingData } | { "event": "ws:m:benchmark", "data": JsonValue };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { JsonValue } from "./serde_json/JsonValue";
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Push a `notifications/claude/channel` event into the recipient's MCP
|
|
6
|
+
* stream. `meta` is forwarded as the event's `meta` object after the shim
|
|
7
|
+
* stringifies its values (Claude Code 2.1.x validates `meta` as
|
|
8
|
+
* `Record<string,string>`).
|
|
9
|
+
*/
|
|
10
|
+
export type NotifyChannel = { content: string, meta: JsonValue, };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { ClientId } from "./ClientId";
|
|
3
|
+
import type { ServerId } from "./ServerId";
|
|
4
|
+
|
|
5
|
+
export type PartialClient = { serverId?: ServerId,
|
|
6
|
+
/**
|
|
7
|
+
* Remote address of the WebSocket connection (e.g., "192.168.1.5:54320").
|
|
8
|
+
*/
|
|
9
|
+
address?: string | null,
|
|
10
|
+
/**
|
|
11
|
+
* ISO timestamp for windback mode. When set, the client sees historical state
|
|
12
|
+
* as of this timestamp instead of live state.
|
|
13
|
+
*/
|
|
14
|
+
windback?: string | null, id?: ClientId, };
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { MessageId } from "./MessageId";
|
|
3
|
+
import type { RoomId } from "./RoomId";
|
|
4
|
+
import type { SessionId } from "./SessionId";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* A message in the bus. Polymorphic recipient — either a peer session
|
|
8
|
+
* (direct send) or a room (broadcast). Exactly one of `to_session_id`
|
|
9
|
+
* and `to_room_id` is set; serde defaults to `None` on the absent
|
|
10
|
+
* side so legacy direct-only payloads from before broadcast existed
|
|
11
|
+
* replay clean.
|
|
12
|
+
*
|
|
13
|
+
* Read state lives on the `MessageRead` join entity, not here, so a
|
|
14
|
+
* broadcast can have per-recipient acks without ambiguity.
|
|
15
|
+
*
|
|
16
|
+
* No denormalized display fields. Sender/recipient labels are computed
|
|
17
|
+
* at read time from the live Session row (and degrade to the session_id
|
|
18
|
+
* itself when the row is gone). Snapshotting nicknames at send time was
|
|
19
|
+
* the source of consistency drift after rename/disconnect; with
|
|
20
|
+
* session_id as the sole stored identity there is nothing to drift.
|
|
21
|
+
*/
|
|
22
|
+
export type PartialMessage = {
|
|
23
|
+
/**
|
|
24
|
+
* Sender's session id. NOT a `belongs_to(Session)` cascade: a sent
|
|
25
|
+
* message must survive the sender exiting so the recipient can still
|
|
26
|
+
* pull it. In the pull-via-hook model the recipient reads on its
|
|
27
|
+
* next turn — which can be after the sender's SessionEnd — so
|
|
28
|
+
* cascading on the sender would silently delete unread messages in
|
|
29
|
+
* that window. The message's lifetime is governed by the *recipient*
|
|
30
|
+
* instead (the `to_session_id` / `to_room_id` cascades below).
|
|
31
|
+
*/
|
|
32
|
+
fromSessionId?: SessionId,
|
|
33
|
+
/**
|
|
34
|
+
* Direct recipient — set for 1:1 sends, `None` for broadcasts.
|
|
35
|
+
* Cascade-DELs the message when the recipient session is DEL'd.
|
|
36
|
+
*/
|
|
37
|
+
toSessionId?: SessionId | null,
|
|
38
|
+
/**
|
|
39
|
+
* Broadcast recipient — set for room sends, `None` for direct
|
|
40
|
+
* sends. Cascade-DELs when the room is DEL'd. (Auto-rooms like
|
|
41
|
+
* `everyone` and `host:*` are never DEL'd, so broadcasts to them
|
|
42
|
+
* effectively persist forever.)
|
|
43
|
+
*/
|
|
44
|
+
toRoomId?: RoomId | null,
|
|
45
|
+
/**
|
|
46
|
+
* When this direct message was addressed to a *human* — via their operator
|
|
47
|
+
* identity (the `op:`/`human:`/email tier of recipient resolution) rather
|
|
48
|
+
* than to one specific agent — this holds that operator string (e.g.
|
|
49
|
+
* `max@lucid.rocks`). The message is still routed to, and cascades on, the
|
|
50
|
+
* operator's most-active session via `to_session_id`; this marks it as
|
|
51
|
+
* human-addressed so the receiving agent surfaces it to its operator
|
|
52
|
+
* instead of treating it as ordinary peer chatter, and the UI console can
|
|
53
|
+
* toast it for that operator regardless of which agent it landed on. `None`
|
|
54
|
+
* for agent-to-agent mail. serde-default so pre-field payloads replay clean.
|
|
55
|
+
*/
|
|
56
|
+
toOperator?: string | null, body?: string,
|
|
57
|
+
/**
|
|
58
|
+
* Wall-clock millis when the daemon accepted the message.
|
|
59
|
+
*/
|
|
60
|
+
sentAt?: bigint, id?: MessageId, };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { MessageId } from "./MessageId";
|
|
3
|
+
import type { MessageReadId } from "./MessageReadId";
|
|
4
|
+
import type { SessionId } from "./SessionId";
|
|
5
|
+
|
|
6
|
+
export type PartialMessageRead = { messageId?: MessageId, sessionId?: SessionId,
|
|
7
|
+
/**
|
|
8
|
+
* Wall-clock millis when this session marked the message read.
|
|
9
|
+
*/
|
|
10
|
+
readAt?: bigint, id?: MessageReadId, };
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { RoomId } from "./RoomId";
|
|
3
|
+
import type { RoomKind } from "./RoomKind";
|
|
4
|
+
|
|
5
|
+
export type PartialRoom = {
|
|
6
|
+
/**
|
|
7
|
+
* Display name. For auto-rooms, equal to `id`. For ad-hoc rooms,
|
|
8
|
+
* the user-supplied label (which `id` is slugified from).
|
|
9
|
+
*/
|
|
10
|
+
name?: string,
|
|
11
|
+
/**
|
|
12
|
+
* Optional human-readable purpose for the room (set by the
|
|
13
|
+
* creator, displayed in `list_rooms`).
|
|
14
|
+
*/
|
|
15
|
+
description?: string | null,
|
|
16
|
+
/**
|
|
17
|
+
* Whether this room is identity-anchored or user-created.
|
|
18
|
+
*/
|
|
19
|
+
kind?: RoomKind,
|
|
20
|
+
/**
|
|
21
|
+
* Wall-clock millis when the room was first created.
|
|
22
|
+
*/
|
|
23
|
+
createdAt?: bigint, id?: RoomId, };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { RoomId } from "./RoomId";
|
|
3
|
+
import type { RoomMemberId } from "./RoomMemberId";
|
|
4
|
+
import type { SessionId } from "./SessionId";
|
|
5
|
+
|
|
6
|
+
export type PartialRoomMember = { roomId?: RoomId, sessionId?: SessionId,
|
|
7
|
+
/**
|
|
8
|
+
* Wall-clock millis when this session first joined this room.
|
|
9
|
+
* Used by `read_messages` visibility rules: members only see
|
|
10
|
+
* messages sent at or after `joined_at` so a re-join doesn't
|
|
11
|
+
* surface back-history they were never part of.
|
|
12
|
+
*/
|
|
13
|
+
joinedAt?: bigint, id?: RoomMemberId, };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { ServerId } from "./ServerId";
|
|
3
|
+
|
|
4
|
+
export type PartialServer = { version?: string, address?: string, port?: number, startedAt?: string, id?: ServerId, };
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { ClientId } from "./ClientId";
|
|
3
|
+
import type { HostInfo } from "./HostInfo";
|
|
4
|
+
import type { SessionId } from "./SessionId";
|
|
5
|
+
|
|
6
|
+
export type PartialSession = {
|
|
7
|
+
/**
|
|
8
|
+
* WebSocket client this session is currently bound to. Auto-populated
|
|
9
|
+
* by the server from the WS connection — clients send the SET command
|
|
10
|
+
* without providing it. There is intentionally no `belongs_to(Client)`
|
|
11
|
+
* cascade: sessions are durable roster entries that survive
|
|
12
|
+
* disconnects (and daemon restarts, via the disk persister). Whether
|
|
13
|
+
* a session's shim is currently live is determined by looking up
|
|
14
|
+
* `client_id` in the Client store; absent there ⇒ disconnected.
|
|
15
|
+
*/
|
|
16
|
+
clientId?: ClientId | null,
|
|
17
|
+
/**
|
|
18
|
+
* OS process id of the connecting client.
|
|
19
|
+
*/
|
|
20
|
+
pid?: number,
|
|
21
|
+
/**
|
|
22
|
+
* Working directory the client launched from.
|
|
23
|
+
*/
|
|
24
|
+
cwd?: string,
|
|
25
|
+
/**
|
|
26
|
+
* Git branch in `cwd`, if it's a repo. Pushed by the shim's HEAD watcher
|
|
27
|
+
* on checkout/switch (event-driven, not sampled at startup) so peers see
|
|
28
|
+
* branch changes mid-session, matching the operator's own statusline.
|
|
29
|
+
*/
|
|
30
|
+
gitBranch?: string | null,
|
|
31
|
+
/**
|
|
32
|
+
* Free-form short status text, settable via the `set_status` command.
|
|
33
|
+
* Surfaces on the roster so peers can see what this session is up to
|
|
34
|
+
* without needing a separate task system.
|
|
35
|
+
*/
|
|
36
|
+
currentTask?: string | null,
|
|
37
|
+
/**
|
|
38
|
+
* Human-facing session name. For Claude Code this is the operator's
|
|
39
|
+
* `/rename` value (Claude's auto-generated title until they rename),
|
|
40
|
+
* read by the shim from Claude's per-PID manifest
|
|
41
|
+
* `~/.claude/sessions/<pid>.json` (`name`) and refreshed when it
|
|
42
|
+
* changes mid-session. Distinct from `nickname` — the daemon-assigned
|
|
43
|
+
* stable handle peers ADDRESS: this is what the human *called* the
|
|
44
|
+
* session, so the roster is legible for cross-repo targeting ("which
|
|
45
|
+
* agent is doing X"). `None` for harnesses with no such manifest
|
|
46
|
+
* (Codex) or Claude builds predating it.
|
|
47
|
+
*/
|
|
48
|
+
sessionName?: string | null,
|
|
49
|
+
/**
|
|
50
|
+
* Live activity / turn-state, from Claude's per-PID manifest `status`:
|
|
51
|
+
* `"busy"` (processing a turn), `"idle"` (awaiting input), or `"shell"`
|
|
52
|
+
* (in a shell command). A truer "is this agent working right now" signal
|
|
53
|
+
* than `last_activity_at`, which only moves on MCP tool calls — an agent
|
|
54
|
+
* can be `busy` for minutes without touching marshal. The shim pushes it
|
|
55
|
+
* event-driven (an fs-watch on the manifest), so the roster tracks
|
|
56
|
+
* turn-state in near real time. `None` for harnesses with no such
|
|
57
|
+
* manifest (Codex) or older Claude builds.
|
|
58
|
+
*/
|
|
59
|
+
activity?: string | null,
|
|
60
|
+
/**
|
|
61
|
+
* Session kind, from the manifest `kind`: `"interactive"` (a human at a
|
|
62
|
+
* terminal) or `"bg"` (a background / headless agent). Set once at
|
|
63
|
+
* registration — it doesn't change over a session's life, so no setter.
|
|
64
|
+
* `None` when unknown (no manifest).
|
|
65
|
+
*/
|
|
66
|
+
kind?: string | null,
|
|
67
|
+
/**
|
|
68
|
+
* Wall-clock millis since unix epoch when the session connected.
|
|
69
|
+
*/
|
|
70
|
+
connectedAt?: bigint,
|
|
71
|
+
/**
|
|
72
|
+
* Wall-clock millis at the most recent shim-side activity (any
|
|
73
|
+
* MCP tool call). Bumped by the shim's `Activity` tracker (the
|
|
74
|
+
* same one that gates the self-update watcher's exec swap) and
|
|
75
|
+
* flushed upstream periodically — `None` until the first push,
|
|
76
|
+
* then a sliding timestamp the roster surfaces uses to compute
|
|
77
|
+
* "did this peer do anything in the last N seconds?". Stale =
|
|
78
|
+
* candidate for the stuck-session visualization.
|
|
79
|
+
*/
|
|
80
|
+
lastActivityAt?: bigint | null,
|
|
81
|
+
/**
|
|
82
|
+
* Name of the most recent MCP tool the shim served (e.g.
|
|
83
|
+
* "send_message", "set_status"). Captures only the tool name —
|
|
84
|
+
* no arguments, no payloads — so the roster can show "this peer
|
|
85
|
+
* last called X 3s ago" without leaking message content. Pair
|
|
86
|
+
* with `last_tool_at` for staleness reasoning.
|
|
87
|
+
*/
|
|
88
|
+
lastTool?: string | null,
|
|
89
|
+
/**
|
|
90
|
+
* Wall-clock millis when `last_tool` was served. Distinct from
|
|
91
|
+
* `last_activity_at` because activity covers all shim traffic
|
|
92
|
+
* (notifications, periodic heartbeats, anything the dispatcher
|
|
93
|
+
* touches) while this is the timestamp of the last *named* MCP
|
|
94
|
+
* tool call. They typically agree, but a session that only
|
|
95
|
+
* receives notifications and never calls a tool will have a
|
|
96
|
+
* fresh `last_activity_at` and a stale `last_tool_at`.
|
|
97
|
+
*/
|
|
98
|
+
lastToolAt?: bigint | null,
|
|
99
|
+
/**
|
|
100
|
+
* Which human this session belongs to. Resolved by the shim:
|
|
101
|
+
* `$MARSHAL_OPERATOR` → `$USER` → `"anonymous"`. Anchors the
|
|
102
|
+
* auto-room `op:<operator>`, so peers can see "all of trevor's
|
|
103
|
+
* sessions" regardless of cwd. `None` for legacy / observer
|
|
104
|
+
* shims that don't set it.
|
|
105
|
+
*/
|
|
106
|
+
operator?: string | null,
|
|
107
|
+
/**
|
|
108
|
+
* Host environment summary the shim populates at startup.
|
|
109
|
+
* Anchors the auto-room `host:<name>`. See `HostInfo`.
|
|
110
|
+
*/
|
|
111
|
+
host?: HostInfo | null,
|
|
112
|
+
/**
|
|
113
|
+
* Project basename — the basename of the git repo root containing
|
|
114
|
+
* this session's `cwd`. Resolved by the shim at startup (the
|
|
115
|
+
* daemon can't run `git` against a remote shim's filesystem).
|
|
116
|
+
* Anchors the auto-room `project:<basename>`. `None` when `cwd`
|
|
117
|
+
* isn't inside a git repo.
|
|
118
|
+
*/
|
|
119
|
+
project?: string | null,
|
|
120
|
+
/**
|
|
121
|
+
* Whether this session can receive LIVE channel pushes — i.e. its
|
|
122
|
+
* claude was launched with `--dangerously-load-development-channels
|
|
123
|
+
* …marshal`. The shim resolves it from the parent process at startup;
|
|
124
|
+
* the daemon can't see it (it's a recipient-host launch detail).
|
|
125
|
+
* `None` = unknown (legacy shim that doesn't report it). `SendMessage`
|
|
126
|
+
* uses it to report `delivered_live` HONESTLY: a live WS client with
|
|
127
|
+
* channels OFF still can't render a push, so the message is queued to
|
|
128
|
+
* the inbox (delivered_live = false) rather than claimed as live.
|
|
129
|
+
*/
|
|
130
|
+
channelsEnabled?: boolean | null, id?: SessionId, };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { SessionNicknameId } from "./SessionNicknameId";
|
|
3
|
+
|
|
4
|
+
export type PartialSessionNickname = {
|
|
5
|
+
/**
|
|
6
|
+
* The assigned `adjective-noun` handle, frozen for this session's life.
|
|
7
|
+
* The entity `id` is the session id it belongs to.
|
|
8
|
+
*/
|
|
9
|
+
nickname?: string, id?: SessionNicknameId, };
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Report that checks whether a peer server client is currently connected.
|
|
5
|
+
* Returns ping in milliseconds when available, otherwise `-1`.
|
|
6
|
+
*/
|
|
7
|
+
export type PeerAlive = { peerId: string, };
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Health snapshot for the persist subsystem.
|
|
5
|
+
*/
|
|
6
|
+
export type PersistHealthStatus = {
|
|
7
|
+
/**
|
|
8
|
+
* Events queued but not yet written.
|
|
9
|
+
*/
|
|
10
|
+
queued: bigint,
|
|
11
|
+
/**
|
|
12
|
+
* Lifetime successful writes.
|
|
13
|
+
*/
|
|
14
|
+
totalPersisted: bigint,
|
|
15
|
+
/**
|
|
16
|
+
* Lifetime failed writes.
|
|
17
|
+
*/
|
|
18
|
+
totalErrors: bigint,
|
|
19
|
+
/**
|
|
20
|
+
* Consecutive failures since last success.
|
|
21
|
+
*/
|
|
22
|
+
consecutiveErrors: bigint,
|
|
23
|
+
/**
|
|
24
|
+
* Most recent error message, if any.
|
|
25
|
+
*/
|
|
26
|
+
lastError?: string | null,
|
|
27
|
+
/**
|
|
28
|
+
* Whether the persister is currently healthy (no consecutive errors).
|
|
29
|
+
*/
|
|
30
|
+
healthy: boolean,
|
|
31
|
+
/**
|
|
32
|
+
* Writes per second over a sliding window.
|
|
33
|
+
*/
|
|
34
|
+
writesPerSecond: number, };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Ping payload for latency measurement
|
|
5
|
+
*/
|
|
6
|
+
export type PingData = {
|
|
7
|
+
/**
|
|
8
|
+
* Unique identifier to correlate ping/pong
|
|
9
|
+
*/
|
|
10
|
+
id: string,
|
|
11
|
+
/**
|
|
12
|
+
* Client-side timestamp when ping was sent (milliseconds since epoch)
|
|
13
|
+
*/
|
|
14
|
+
timestamp: bigint, };
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { RoomId } from "./RoomId";
|
|
3
|
+
import type { SessionId } from "./SessionId";
|
|
4
|
+
|
|
5
|
+
export type ReadMessages = {
|
|
6
|
+
/**
|
|
7
|
+
* Filter to messages addressed to this room. Polymorphic id —
|
|
8
|
+
* `everyone`, `host:*`, `op:*`, `project:*`, or any ad-hoc room
|
|
9
|
+
* id.
|
|
10
|
+
*/
|
|
11
|
+
room?: RoomId | null,
|
|
12
|
+
/**
|
|
13
|
+
* Filter to messages from this sender (`from_session_id`).
|
|
14
|
+
*/
|
|
15
|
+
from?: SessionId | null,
|
|
16
|
+
/**
|
|
17
|
+
* Filter to messages addressed to this session_id (direct only).
|
|
18
|
+
*/
|
|
19
|
+
toSession?: SessionId | null,
|
|
20
|
+
/**
|
|
21
|
+
* Restrict to messages addressed to me (direct OR via room
|
|
22
|
+
* membership). Combine with `unread` for the classic inbox view.
|
|
23
|
+
*/
|
|
24
|
+
inbox: boolean,
|
|
25
|
+
/**
|
|
26
|
+
* Restrict to messages I sent.
|
|
27
|
+
*/
|
|
28
|
+
sent: boolean,
|
|
29
|
+
/**
|
|
30
|
+
* Restrict to messages I haven't acked yet (no `MessageRead` row
|
|
31
|
+
* for me).
|
|
32
|
+
*/
|
|
33
|
+
unread: boolean,
|
|
34
|
+
/**
|
|
35
|
+
* `sent_at >= since` (millis). Useful for incremental catch-up.
|
|
36
|
+
*/
|
|
37
|
+
since?: bigint | null,
|
|
38
|
+
/**
|
|
39
|
+
* Cap on returned messages (default 50, max 500).
|
|
40
|
+
*/
|
|
41
|
+
limit?: number | null,
|
|
42
|
+
/**
|
|
43
|
+
* Self-identified caller — whose inbox/sent view this is — for
|
|
44
|
+
* connectionless paths (HTTP-MCP agents, the daemon's `/hook/*`
|
|
45
|
+
* handlers reading on a session's behalf). WS shim callers omit it
|
|
46
|
+
* and the caller is derived from the connection. See `resolve_caller`.
|
|
47
|
+
*/
|
|
48
|
+
asSession?: SessionId | null, };
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { RoomId } from "./RoomId";
|
|
3
|
+
import type { SessionId } from "./SessionId";
|
|
4
|
+
|
|
5
|
+
export type ReadMessagesArgs = {
|
|
6
|
+
/**
|
|
7
|
+
* Filter to messages addressed to this room. Polymorphic id —
|
|
8
|
+
* `everyone`, `host:*`, `op:*`, `project:*`, or any ad-hoc room
|
|
9
|
+
* id.
|
|
10
|
+
*/
|
|
11
|
+
room?: RoomId | null,
|
|
12
|
+
/**
|
|
13
|
+
* Filter to messages from this sender (`from_session_id`).
|
|
14
|
+
*/
|
|
15
|
+
from?: SessionId | null,
|
|
16
|
+
/**
|
|
17
|
+
* Filter to messages addressed to this session_id (direct only).
|
|
18
|
+
*/
|
|
19
|
+
toSession?: SessionId | null,
|
|
20
|
+
/**
|
|
21
|
+
* Restrict to messages addressed to me (direct OR via room
|
|
22
|
+
* membership). Combine with `unread` for the classic inbox view.
|
|
23
|
+
*/
|
|
24
|
+
inbox: boolean,
|
|
25
|
+
/**
|
|
26
|
+
* Restrict to messages I sent.
|
|
27
|
+
*/
|
|
28
|
+
sent: boolean,
|
|
29
|
+
/**
|
|
30
|
+
* Restrict to messages I haven't acked yet (no `MessageRead` row
|
|
31
|
+
* for me).
|
|
32
|
+
*/
|
|
33
|
+
unread: boolean,
|
|
34
|
+
/**
|
|
35
|
+
* `sent_at >= since` (millis). Useful for incremental catch-up.
|
|
36
|
+
*/
|
|
37
|
+
since?: bigint | null,
|
|
38
|
+
/**
|
|
39
|
+
* Cap on returned messages (default 50, max 500).
|
|
40
|
+
*/
|
|
41
|
+
limit?: number | null,
|
|
42
|
+
/**
|
|
43
|
+
* Self-identified caller — whose inbox/sent view this is — for
|
|
44
|
+
* connectionless paths (HTTP-MCP agents, the daemon's `/hook/*`
|
|
45
|
+
* handlers reading on a session's behalf). WS shim callers omit it
|
|
46
|
+
* and the caller is derived from the connection. See `resolve_caller`.
|
|
47
|
+
*/
|
|
48
|
+
asSession?: SessionId | null, };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { MessageView } from "./MessageView";
|
|
3
|
+
|
|
4
|
+
export type ReadMessagesResult = { messages: Array<MessageView>,
|
|
5
|
+
/**
|
|
6
|
+
* Number of messages that matched the filters before `limit`
|
|
7
|
+
* truncation — useful for "showing N of M" UX.
|
|
8
|
+
*/
|
|
9
|
+
totalMatched: number, };
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
+
import type { RoomId } from "./RoomId";
|
|
3
|
+
import type { RoomKind } from "./RoomKind";
|
|
4
|
+
|
|
5
|
+
export type Room = {
|
|
6
|
+
/**
|
|
7
|
+
* Display name. For auto-rooms, equal to `id`. For ad-hoc rooms,
|
|
8
|
+
* the user-supplied label (which `id` is slugified from).
|
|
9
|
+
*/
|
|
10
|
+
name: string,
|
|
11
|
+
/**
|
|
12
|
+
* Optional human-readable purpose for the room (set by the
|
|
13
|
+
* creator, displayed in `list_rooms`).
|
|
14
|
+
*/
|
|
15
|
+
description?: string | null,
|
|
16
|
+
/**
|
|
17
|
+
* Whether this room is identity-anchored or user-created.
|
|
18
|
+
*/
|
|
19
|
+
kind: RoomKind,
|
|
20
|
+
/**
|
|
21
|
+
* Wall-clock millis when the room was first created.
|
|
22
|
+
*/
|
|
23
|
+
createdAt: bigint, id: RoomId, };
|