@joe-broadhead/messaging 0.7.0 → 0.8.0
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/CHANGELOG.md +259 -2
- package/dist/bin/messaging-mcp.js +5484 -3858
- package/dist/bin/messaging-relay.js +4728 -1136
- package/dist/bin/messaging.js +4616 -2807
- package/dist/bin/messagingd.js +16451 -9444
- package/dist/lib/modules/core/agent/operations.js +19 -327
- package/dist/lib/modules/core/agent/present.js +15 -55
- package/dist/lib/modules/core/agent-tools.js +46 -143
- package/dist/lib/modules/core/consent.js +1 -1
- package/dist/lib/modules/core/conversation/context.js +80 -0
- package/dist/lib/modules/core/conversation/event.js +125 -0
- package/dist/lib/modules/core/conversation/guest-invitation.js +42 -0
- package/dist/lib/modules/core/conversation/ids.js +38 -0
- package/dist/lib/modules/core/conversation/link.js +35 -0
- package/dist/lib/modules/core/conversation/log.js +988 -0
- package/dist/lib/modules/core/conversation/ratchet.js +243 -0
- package/dist/lib/modules/core/conversation/request-log.js +158 -0
- package/dist/lib/modules/core/conversation/request-seal.js +41 -0
- package/dist/lib/modules/core/conversation/requests.js +87 -0
- package/dist/lib/modules/core/conversation/seal.js +251 -0
- package/dist/lib/modules/core/conversation-agent-tools.js +69 -0
- package/dist/lib/modules/core/federation/directory-proof.js +83 -0
- package/dist/lib/modules/core/federation/proof-state.js +167 -0
- package/dist/lib/modules/core/federation/roster-proof.js +74 -0
- package/dist/lib/modules/core/index.js +16 -2
- package/dist/lib/modules/core/jelly-host.js +5 -5
- package/dist/lib/modules/core/schema/common.js +85 -3
- package/dist/lib/modules/core/schema/consent.js +5 -4
- package/dist/lib/modules/core/schema/contact-request.js +22 -0
- package/dist/lib/modules/core/schema/conv-frames.js +94 -0
- package/dist/lib/modules/core/schema/conversation.js +326 -0
- package/dist/lib/modules/core/schema/envelope.js +8 -24
- package/dist/lib/modules/core/schema/errors.js +42 -2
- package/dist/lib/modules/core/schema/guest-invitation.js +13 -0
- package/dist/lib/modules/core/schema/index.js +6 -0
- package/dist/lib/modules/core/schema/ipc/consent.js +13 -9
- package/dist/lib/modules/core/schema/ipc/conversation-views.js +80 -0
- package/dist/lib/modules/core/schema/ipc/conversations.js +128 -0
- package/dist/lib/modules/core/schema/ipc/device.js +2 -0
- package/dist/lib/modules/core/schema/ipc/jelly.js +3 -38
- package/dist/lib/modules/core/schema/ipc/shapes.js +14 -72
- package/dist/lib/modules/core/schema/ipc/surfaces.js +12 -195
- package/dist/lib/modules/core/schema/ipc/tasks.js +31 -0
- package/dist/lib/modules/core/schema/ipc.js +18 -44
- package/dist/lib/modules/core/testing.js +1 -0
- package/dist/lib/modules/core/version.js +1 -1
- package/dist/lib/modules/ipc/client.js +10 -2
- package/dist/lib/modules/ipc/server.js +14 -5
- package/dist/lib/modules/ipc/testing.js +13 -23
- package/dist/spec/messaging-v1.md +835 -380
- package/dist/third-party-notices.md +1 -1
- package/dist/third-party.json +1 -1
- package/dist/types/core/agent/operations.d.ts +5 -52
- package/dist/types/core/agent/present.d.ts +6 -21
- package/dist/types/core/agent-tools.d.ts +277 -438
- package/dist/types/core/conversation/context.d.ts +56 -0
- package/dist/types/core/conversation/event.d.ts +36 -0
- package/dist/types/core/conversation/guest-invitation.d.ts +8 -0
- package/dist/types/core/conversation/ids.d.ts +18 -0
- package/dist/types/core/conversation/link.d.ts +16 -0
- package/dist/types/core/conversation/log.d.ts +157 -0
- package/dist/types/core/conversation/ratchet.d.ts +95 -0
- package/dist/types/core/conversation/request-log.d.ts +24 -0
- package/dist/types/core/conversation/request-seal.d.ts +6 -0
- package/dist/types/core/conversation/requests.d.ts +14 -0
- package/dist/types/core/conversation/seal.d.ts +70 -0
- package/dist/types/core/conversation-agent-tools.d.ts +918 -0
- package/dist/types/core/federation/directory-proof.d.ts +8 -0
- package/dist/types/core/federation/proof-state.d.ts +114 -0
- package/dist/types/core/federation/roster-proof.d.ts +7 -0
- package/dist/types/core/index.d.ts +15 -3
- package/dist/types/core/jelly-host.d.ts +1 -1
- package/dist/types/core/schema/common.d.ts +85 -4
- package/dist/types/core/schema/consent.d.ts +7 -7
- package/dist/types/core/schema/contact-request.d.ts +264 -0
- package/dist/types/core/schema/conv-frames.d.ts +1200 -0
- package/dist/types/core/schema/conversation.d.ts +2803 -0
- package/dist/types/core/schema/envelope.d.ts +89 -130
- package/dist/types/core/schema/errors.d.ts +40 -0
- package/dist/types/core/schema/guest-invitation.d.ts +51 -0
- package/dist/types/core/schema/index.d.ts +6 -0
- package/dist/types/core/schema/ipc/consent.d.ts +89 -49
- package/dist/types/core/schema/ipc/conversation-views.d.ts +1023 -0
- package/dist/types/core/schema/ipc/conversations.d.ts +3987 -0
- package/dist/types/core/schema/ipc/device.d.ts +10 -0
- package/dist/types/core/schema/ipc/jelly.d.ts +2 -105
- package/dist/types/core/schema/ipc/shapes.d.ts +16 -95
- package/dist/types/core/schema/ipc/surfaces.d.ts +28 -424
- package/dist/types/core/schema/ipc/tasks.d.ts +208 -0
- package/dist/types/core/schema/ipc.d.ts +2684 -523
- package/dist/types/core/schema/relay.d.ts +20 -4
- package/dist/types/core/testing.d.ts +1 -0
- package/dist/types/core/version.d.ts +1 -1
- package/dist/types/ipc/client.d.ts +4 -1
- package/dist/types/ipc/server.d.ts +10 -1
- package/dist/types/ipc/testing.d.ts +21 -8
- package/package.json +1 -1
|
@@ -116,6 +116,7 @@ export declare const DeviceListEntry: z.ZodObject<{
|
|
|
116
116
|
}>>;
|
|
117
117
|
current: z.ZodBoolean;
|
|
118
118
|
self: z.ZodBoolean;
|
|
119
|
+
away: z.ZodOptional<z.ZodLiteral<true>>;
|
|
119
120
|
since: z.ZodOptional<z.ZodNumber>;
|
|
120
121
|
unbound: z.ZodOptional<z.ZodObject<{
|
|
121
122
|
at: z.ZodNumber;
|
|
@@ -220,6 +221,7 @@ export declare const LoginState: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
220
221
|
refused: "refused";
|
|
221
222
|
declined: "declined";
|
|
222
223
|
request_required: "request_required";
|
|
224
|
+
peer_outdated: "peer_outdated";
|
|
223
225
|
rate_limited: "rate_limited";
|
|
224
226
|
loop_guard: "loop_guard";
|
|
225
227
|
too_large: "too_large";
|
|
@@ -236,6 +238,8 @@ export declare const LoginState: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
236
238
|
binding_invalid: "binding_invalid";
|
|
237
239
|
jelly_unavailable: "jelly_unavailable";
|
|
238
240
|
log_conflict: "log_conflict";
|
|
241
|
+
conv_conflict: "conv_conflict";
|
|
242
|
+
stale_epoch: "stale_epoch";
|
|
239
243
|
device_limit: "device_limit";
|
|
240
244
|
admission_required: "admission_required";
|
|
241
245
|
admission_invalid: "admission_invalid";
|
|
@@ -250,6 +254,7 @@ export declare const LoginState: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
250
254
|
ticket_invalid: "ticket_invalid";
|
|
251
255
|
daemon_unavailable: "daemon_unavailable";
|
|
252
256
|
daemon_mismatch: "daemon_mismatch";
|
|
257
|
+
store_refused: "store_refused";
|
|
253
258
|
internal: "internal";
|
|
254
259
|
}>;
|
|
255
260
|
message: z.ZodString;
|
|
@@ -366,6 +371,7 @@ export declare const DEVICE_METHODS: {
|
|
|
366
371
|
}>>;
|
|
367
372
|
current: z.ZodBoolean;
|
|
368
373
|
self: z.ZodBoolean;
|
|
374
|
+
away: z.ZodOptional<z.ZodLiteral<true>>;
|
|
369
375
|
since: z.ZodOptional<z.ZodNumber>;
|
|
370
376
|
unbound: z.ZodOptional<z.ZodObject<{
|
|
371
377
|
at: z.ZodNumber;
|
|
@@ -507,6 +513,7 @@ export declare const DEVICE_METHODS: {
|
|
|
507
513
|
refused: "refused";
|
|
508
514
|
declined: "declined";
|
|
509
515
|
request_required: "request_required";
|
|
516
|
+
peer_outdated: "peer_outdated";
|
|
510
517
|
rate_limited: "rate_limited";
|
|
511
518
|
loop_guard: "loop_guard";
|
|
512
519
|
too_large: "too_large";
|
|
@@ -523,6 +530,8 @@ export declare const DEVICE_METHODS: {
|
|
|
523
530
|
binding_invalid: "binding_invalid";
|
|
524
531
|
jelly_unavailable: "jelly_unavailable";
|
|
525
532
|
log_conflict: "log_conflict";
|
|
533
|
+
conv_conflict: "conv_conflict";
|
|
534
|
+
stale_epoch: "stale_epoch";
|
|
526
535
|
device_limit: "device_limit";
|
|
527
536
|
admission_required: "admission_required";
|
|
528
537
|
admission_invalid: "admission_invalid";
|
|
@@ -537,6 +546,7 @@ export declare const DEVICE_METHODS: {
|
|
|
537
546
|
ticket_invalid: "ticket_invalid";
|
|
538
547
|
daemon_unavailable: "daemon_unavailable";
|
|
539
548
|
daemon_mismatch: "daemon_mismatch";
|
|
549
|
+
store_refused: "store_refused";
|
|
540
550
|
internal: "internal";
|
|
541
551
|
}>;
|
|
542
552
|
message: z.ZodString;
|
|
@@ -2,8 +2,7 @@
|
|
|
2
2
|
* The IPC methods a Jelly host needs (spec §8.2, §8.11; design §13.6, §13.10-§13.12), served in every deployment:
|
|
3
3
|
*
|
|
4
4
|
* - Agent tier: `daemon.health`, a cheap status with no secrets and no counts.
|
|
5
|
-
* - Human tier: `
|
|
6
|
-
* `notice.subscribe`, `notice.list` and `notice.ack` (notices in fixed categories), and the read-only preview
|
|
5
|
+
* - Human tier: `notice.subscribe`, `notice.list` and `notice.ack` (notices in fixed categories), and the read-only preview
|
|
7
6
|
* `device.remove.preview`.
|
|
8
7
|
*
|
|
9
8
|
* Spread into `IPC_METHODS`; `HOST_SCOPE_METHODS` (in `ipc.ts`) is what a host-scope action grant allows.
|
|
@@ -77,7 +76,6 @@ export declare const Notice: z.ZodObject<{
|
|
|
77
76
|
request: "request";
|
|
78
77
|
alert: "alert";
|
|
79
78
|
}>;
|
|
80
|
-
conversation: z.ZodOptional<z.ZodString>;
|
|
81
79
|
from: z.ZodOptional<z.ZodObject<{
|
|
82
80
|
name: z.ZodString;
|
|
83
81
|
email: z.ZodOptional<z.ZodString>;
|
|
@@ -128,9 +126,8 @@ export declare const Notice: z.ZodObject<{
|
|
|
128
126
|
at: z.ZodNumber;
|
|
129
127
|
}, z.core.$strip>;
|
|
130
128
|
export type Notice = z.infer<typeof Notice>;
|
|
131
|
-
/** What the person's badges count:
|
|
129
|
+
/** What the person's badges count: requests held for them. Conversation read state remains staged. */
|
|
132
130
|
export declare const NoticeCounts: z.ZodObject<{
|
|
133
|
-
unread: z.ZodNumber;
|
|
134
131
|
requests: z.ZodNumber;
|
|
135
132
|
}, z.core.$strip>;
|
|
136
133
|
/** `daemon.health` (spec §8.2): the daemon's state, with no secrets and no counts. */
|
|
@@ -160,18 +157,6 @@ export declare const DaemonHealth: z.ZodObject<{
|
|
|
160
157
|
storeSchema: z.ZodNumber;
|
|
161
158
|
}, z.core.$strip>;
|
|
162
159
|
export type DaemonHealth = z.infer<typeof DaemonHealth>;
|
|
163
|
-
/** One local agent (a registered or kept session) and its traffic on this device. */
|
|
164
|
-
export declare const AgentSummary: z.ZodObject<{
|
|
165
|
-
agent: z.ZodString;
|
|
166
|
-
conversations: z.ZodNumber;
|
|
167
|
-
unread: z.ZodNumber;
|
|
168
|
-
lastAt: z.ZodOptional<z.ZodNumber>;
|
|
169
|
-
state: z.ZodEnum<{
|
|
170
|
-
idle: "idle";
|
|
171
|
-
busy: "busy";
|
|
172
|
-
kept: "kept";
|
|
173
|
-
}>;
|
|
174
|
-
}, z.core.$strip>;
|
|
175
160
|
export declare const JELLY_METHODS: {
|
|
176
161
|
/**
|
|
177
162
|
* Agent tier. A cheap status for a host that polls: the daemon's state, the relay, the directory, an alarm, and
|
|
@@ -205,92 +190,6 @@ export declare const JELLY_METHODS: {
|
|
|
205
190
|
storeSchema: z.ZodNumber;
|
|
206
191
|
}, z.core.$strip>;
|
|
207
192
|
};
|
|
208
|
-
/** Human tier. This person's local agents on this device, most recent first. Read-only. */
|
|
209
|
-
readonly "agents.list": {
|
|
210
|
-
readonly params: z.ZodObject<{}, z.core.$strict>;
|
|
211
|
-
readonly result: z.ZodObject<{
|
|
212
|
-
agents: z.ZodArray<z.ZodObject<{
|
|
213
|
-
agent: z.ZodString;
|
|
214
|
-
conversations: z.ZodNumber;
|
|
215
|
-
unread: z.ZodNumber;
|
|
216
|
-
lastAt: z.ZodOptional<z.ZodNumber>;
|
|
217
|
-
state: z.ZodEnum<{
|
|
218
|
-
idle: "idle";
|
|
219
|
-
busy: "busy";
|
|
220
|
-
kept: "kept";
|
|
221
|
-
}>;
|
|
222
|
-
}, z.core.$strip>>;
|
|
223
|
-
}, z.core.$strip>;
|
|
224
|
-
};
|
|
225
|
-
/**
|
|
226
|
-
* Human tier. One local agent's traffic: without `conversation`, the other agents it has mail or tasks with, most
|
|
227
|
-
* recent first; with `conversation` (`agent:<person>/<agent>`), a page of its entries, as `conv.read` gives them to
|
|
228
|
-
* the agent, latest first unless `before` names an entry. Changes no stage and sends no receipt. Peer text is
|
|
229
|
-
* untrusted: a client cleans it for display.
|
|
230
|
-
*/
|
|
231
|
-
readonly "agents.read": {
|
|
232
|
-
readonly params: z.ZodObject<{
|
|
233
|
-
agent: z.ZodString;
|
|
234
|
-
conversation: z.ZodOptional<z.ZodString>;
|
|
235
|
-
before: z.ZodOptional<z.ZodObject<{
|
|
236
|
-
at: z.ZodNumber;
|
|
237
|
-
id: z.ZodString;
|
|
238
|
-
}, z.core.$strict>>;
|
|
239
|
-
limit: z.ZodOptional<z.ZodNumber>;
|
|
240
|
-
}, z.core.$strict>;
|
|
241
|
-
readonly result: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
242
|
-
kind: z.ZodLiteral<"conversations">;
|
|
243
|
-
conversations: z.ZodArray<z.ZodObject<{
|
|
244
|
-
conversation: z.ZodString;
|
|
245
|
-
unread: z.ZodNumber;
|
|
246
|
-
lastAt: z.ZodNumber;
|
|
247
|
-
}, z.core.$strip>>;
|
|
248
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
249
|
-
kind: z.ZodLiteral<"entries">;
|
|
250
|
-
conversation: z.ZodString;
|
|
251
|
-
entries: z.ZodArray<z.ZodObject<{
|
|
252
|
-
id: z.ZodString;
|
|
253
|
-
kind: z.ZodEnum<{
|
|
254
|
-
task: "task";
|
|
255
|
-
mail: "mail";
|
|
256
|
-
}>;
|
|
257
|
-
direction: z.ZodEnum<{
|
|
258
|
-
out: "out";
|
|
259
|
-
in: "in";
|
|
260
|
-
}>;
|
|
261
|
-
peer: z.ZodString;
|
|
262
|
-
at: z.ZodNumber;
|
|
263
|
-
text: z.ZodOptional<z.ZodString>;
|
|
264
|
-
taskId: z.ZodOptional<z.ZodString>;
|
|
265
|
-
stage: z.ZodOptional<z.ZodEnum<{
|
|
266
|
-
accepted: "accepted";
|
|
267
|
-
relayed: "relayed";
|
|
268
|
-
delivered: "delivered";
|
|
269
|
-
held: "held";
|
|
270
|
-
handed_to_agent: "handed_to_agent";
|
|
271
|
-
read: "read";
|
|
272
|
-
replied: "replied";
|
|
273
|
-
rejected: "rejected";
|
|
274
|
-
expired: "expired";
|
|
275
|
-
}>>;
|
|
276
|
-
role: z.ZodOptional<z.ZodEnum<{
|
|
277
|
-
requester: "requester";
|
|
278
|
-
executor: "executor";
|
|
279
|
-
}>>;
|
|
280
|
-
state: z.ZodOptional<z.ZodEnum<{
|
|
281
|
-
TASK_STATE_SUBMITTED: "TASK_STATE_SUBMITTED";
|
|
282
|
-
TASK_STATE_WORKING: "TASK_STATE_WORKING";
|
|
283
|
-
TASK_STATE_COMPLETED: "TASK_STATE_COMPLETED";
|
|
284
|
-
TASK_STATE_FAILED: "TASK_STATE_FAILED";
|
|
285
|
-
TASK_STATE_CANCELED: "TASK_STATE_CANCELED";
|
|
286
|
-
TASK_STATE_INPUT_REQUIRED: "TASK_STATE_INPUT_REQUIRED";
|
|
287
|
-
TASK_STATE_REJECTED: "TASK_STATE_REJECTED";
|
|
288
|
-
TASK_STATE_AUTH_REQUIRED: "TASK_STATE_AUTH_REQUIRED";
|
|
289
|
-
}>>;
|
|
290
|
-
}, z.core.$strip>>;
|
|
291
|
-
more: z.ZodBoolean;
|
|
292
|
-
}, z.core.$strip>], "kind">;
|
|
293
|
-
};
|
|
294
193
|
/**
|
|
295
194
|
* Human tier; host scope in `deployment: "jelly"`. Replays the unacknowledged notices after `after` (all of them
|
|
296
195
|
* without it), oldest first, as `notice` events on this connection, then sends each new one. With `lines`, a
|
|
@@ -319,7 +218,6 @@ export declare const JELLY_METHODS: {
|
|
|
319
218
|
request: "request";
|
|
320
219
|
alert: "alert";
|
|
321
220
|
}>;
|
|
322
|
-
conversation: z.ZodOptional<z.ZodString>;
|
|
323
221
|
from: z.ZodOptional<z.ZodObject<{
|
|
324
222
|
name: z.ZodString;
|
|
325
223
|
email: z.ZodOptional<z.ZodString>;
|
|
@@ -370,7 +268,6 @@ export declare const JELLY_METHODS: {
|
|
|
370
268
|
at: z.ZodNumber;
|
|
371
269
|
}, z.core.$strip>>;
|
|
372
270
|
counts: z.ZodObject<{
|
|
373
|
-
unread: z.ZodNumber;
|
|
374
271
|
requests: z.ZodNumber;
|
|
375
272
|
}, z.core.$strip>;
|
|
376
273
|
}, z.core.$strip>;
|
|
@@ -21,8 +21,8 @@ export type SessionKey = z.infer<typeof SessionKey>;
|
|
|
21
21
|
*/
|
|
22
22
|
export declare const SendExpect: z.ZodEnum<{
|
|
23
23
|
kept: "kept";
|
|
24
|
-
next_turn: "next_turn";
|
|
25
24
|
wake: "wake";
|
|
25
|
+
next_turn: "next_turn";
|
|
26
26
|
next_prompt: "next_prompt";
|
|
27
27
|
on_read: "on_read";
|
|
28
28
|
offline: "offline";
|
|
@@ -52,45 +52,14 @@ export declare const DirectoryEntry: z.ZodObject<{
|
|
|
52
52
|
self: z.ZodBoolean;
|
|
53
53
|
expect: z.ZodOptional<z.ZodEnum<{
|
|
54
54
|
kept: "kept";
|
|
55
|
-
next_turn: "next_turn";
|
|
56
55
|
wake: "wake";
|
|
56
|
+
next_turn: "next_turn";
|
|
57
57
|
next_prompt: "next_prompt";
|
|
58
58
|
on_read: "on_read";
|
|
59
59
|
offline: "offline";
|
|
60
60
|
}>>;
|
|
61
61
|
}, z.core.$strip>;
|
|
62
62
|
export type DirectoryEntry = z.infer<typeof DirectoryEntry>;
|
|
63
|
-
/** Chat text, at most `LIMITS.chatChars` UTF-16 code units (`max` would count code points). */
|
|
64
|
-
export declare const ChatText: z.ZodString;
|
|
65
|
-
/**
|
|
66
|
-
* A position in this machine's chat order (spec §6.8): every filed line and every chat change takes
|
|
67
|
-
* the next one. Local: another machine numbers the same line differently. 0 is before the first.
|
|
68
|
-
*/
|
|
69
|
-
export declare const ChatSeq: z.ZodNumber;
|
|
70
|
-
export type ChatSeq = z.infer<typeof ChatSeq>;
|
|
71
|
-
/** One transcript line (spec §6.8). `id` is the line's `messageId`, the same on every machine. */
|
|
72
|
-
export declare const ChatLine: z.ZodObject<{
|
|
73
|
-
id: z.ZodString;
|
|
74
|
-
seq: z.ZodNumber;
|
|
75
|
-
at: z.ZodNumber;
|
|
76
|
-
person: z.ZodUnion<readonly [z.ZodString, z.ZodString]>;
|
|
77
|
-
agent: z.ZodOptional<z.ZodString>;
|
|
78
|
-
direction: z.ZodEnum<{
|
|
79
|
-
out: "out";
|
|
80
|
-
in: "in";
|
|
81
|
-
}>;
|
|
82
|
-
body: z.ZodString;
|
|
83
|
-
thread: z.ZodOptional<z.ZodString>;
|
|
84
|
-
state: z.ZodOptional<z.ZodEnum<{
|
|
85
|
-
delivered: "delivered";
|
|
86
|
-
held: "held";
|
|
87
|
-
refused: "refused";
|
|
88
|
-
sent: "sent";
|
|
89
|
-
}>>;
|
|
90
|
-
refused: z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodString]>>>;
|
|
91
|
-
notice: z.ZodOptional<z.ZodLiteral<true>>;
|
|
92
|
-
}, z.core.$strip>;
|
|
93
|
-
export type ChatLine = z.infer<typeof ChatLine>;
|
|
94
63
|
/** The other end of an item or a task: a person's device and, when an agent wrote it, the agent. */
|
|
95
64
|
export declare const PeerRef: z.ZodObject<{
|
|
96
65
|
address: z.ZodString;
|
|
@@ -104,12 +73,14 @@ export declare const InboxItem: z.ZodObject<{
|
|
|
104
73
|
id: z.ZodString;
|
|
105
74
|
key: z.ZodString;
|
|
106
75
|
from: z.ZodObject<{
|
|
107
|
-
address: z.ZodString;
|
|
108
76
|
person: z.ZodUnion<readonly [z.ZodString, z.ZodString]>;
|
|
109
77
|
agent: z.ZodOptional<z.ZodString>;
|
|
110
|
-
|
|
111
|
-
|
|
78
|
+
address: z.ZodUnion<readonly [z.ZodString, z.ZodString]>;
|
|
79
|
+
device: z.ZodOptional<z.ZodString>;
|
|
80
|
+
label: z.ZodOptional<z.ZodString>;
|
|
112
81
|
}, z.core.$strip>;
|
|
82
|
+
cid: z.ZodOptional<z.ZodString>;
|
|
83
|
+
eventId: z.ZodOptional<z.ZodString>;
|
|
113
84
|
kind: z.ZodEnum<{
|
|
114
85
|
message: "message";
|
|
115
86
|
task: "task";
|
|
@@ -142,8 +113,7 @@ export declare const InboxItem: z.ZodObject<{
|
|
|
142
113
|
}, z.core.$strip>;
|
|
143
114
|
export type InboxItem = z.infer<typeof InboxItem>;
|
|
144
115
|
/**
|
|
145
|
-
* A
|
|
146
|
-
* and the `taskId`), and how far it got, from this daemon's own delivery records (spec §6.3).
|
|
116
|
+
* A task continuation and its stage from this daemon's own delivery records (spec §6.3).
|
|
147
117
|
*/
|
|
148
118
|
export declare const TaskFollowUp: z.ZodObject<{
|
|
149
119
|
envelopeId: z.ZodString;
|
|
@@ -281,13 +251,12 @@ export declare const TaskRecord: z.ZodObject<{
|
|
|
281
251
|
}, z.core.$strip>;
|
|
282
252
|
export type TaskRecord = z.infer<typeof TaskRecord>;
|
|
283
253
|
/**
|
|
284
|
-
* Where a
|
|
285
|
-
* from an agent to them) or `#<channel>` (a post).
|
|
254
|
+
* Where a retained task envelope went: an agent session `person/agent@label`.
|
|
286
255
|
*/
|
|
287
|
-
export declare const SendTarget: z.
|
|
256
|
+
export declare const SendTarget: z.ZodString;
|
|
288
257
|
export type SendTarget = z.infer<typeof SendTarget>;
|
|
289
258
|
export declare const SendResult: z.ZodObject<{
|
|
290
|
-
to: z.
|
|
259
|
+
to: z.ZodString;
|
|
291
260
|
envelopeId: z.ZodString;
|
|
292
261
|
messageId: z.ZodString;
|
|
293
262
|
taskId: z.ZodOptional<z.ZodString>;
|
|
@@ -315,6 +284,7 @@ export declare const SendResult: z.ZodObject<{
|
|
|
315
284
|
refused: "refused";
|
|
316
285
|
declined: "declined";
|
|
317
286
|
request_required: "request_required";
|
|
287
|
+
peer_outdated: "peer_outdated";
|
|
318
288
|
rate_limited: "rate_limited";
|
|
319
289
|
loop_guard: "loop_guard";
|
|
320
290
|
too_large: "too_large";
|
|
@@ -331,6 +301,8 @@ export declare const SendResult: z.ZodObject<{
|
|
|
331
301
|
binding_invalid: "binding_invalid";
|
|
332
302
|
jelly_unavailable: "jelly_unavailable";
|
|
333
303
|
log_conflict: "log_conflict";
|
|
304
|
+
conv_conflict: "conv_conflict";
|
|
305
|
+
stale_epoch: "stale_epoch";
|
|
334
306
|
device_limit: "device_limit";
|
|
335
307
|
admission_required: "admission_required";
|
|
336
308
|
admission_invalid: "admission_invalid";
|
|
@@ -345,67 +317,16 @@ export declare const SendResult: z.ZodObject<{
|
|
|
345
317
|
ticket_invalid: "ticket_invalid";
|
|
346
318
|
daemon_unavailable: "daemon_unavailable";
|
|
347
319
|
daemon_mismatch: "daemon_mismatch";
|
|
320
|
+
store_refused: "store_refused";
|
|
348
321
|
internal: "internal";
|
|
349
322
|
}>>;
|
|
350
323
|
expect: z.ZodOptional<z.ZodEnum<{
|
|
351
324
|
kept: "kept";
|
|
352
|
-
next_turn: "next_turn";
|
|
353
325
|
wake: "wake";
|
|
326
|
+
next_turn: "next_turn";
|
|
354
327
|
next_prompt: "next_prompt";
|
|
355
328
|
on_read: "on_read";
|
|
356
329
|
offline: "offline";
|
|
357
330
|
}>>;
|
|
358
331
|
}, z.core.$strip>;
|
|
359
332
|
export type SendResult = z.infer<typeof SendResult>;
|
|
360
|
-
/** A place in a conversation page (`conv.read`): an entry's time and id. */
|
|
361
|
-
export declare const ConvCursor: z.ZodObject<{
|
|
362
|
-
at: z.ZodNumber;
|
|
363
|
-
id: z.ZodString;
|
|
364
|
-
}, z.core.$strict>;
|
|
365
|
-
export type ConvCursor = z.infer<typeof ConvCursor>;
|
|
366
|
-
/**
|
|
367
|
-
* One entry of a conversation between a local session and one other session (spec §8.2
|
|
368
|
-
* `conv.read`): mail either way, or a task either way. `text` is untrusted peer text for incoming
|
|
369
|
-
* mail and for a task the other side asked for; clients frame it as data.
|
|
370
|
-
*/
|
|
371
|
-
export declare const ConvEntry: z.ZodObject<{
|
|
372
|
-
id: z.ZodString;
|
|
373
|
-
kind: z.ZodEnum<{
|
|
374
|
-
task: "task";
|
|
375
|
-
mail: "mail";
|
|
376
|
-
}>;
|
|
377
|
-
direction: z.ZodEnum<{
|
|
378
|
-
out: "out";
|
|
379
|
-
in: "in";
|
|
380
|
-
}>;
|
|
381
|
-
peer: z.ZodString;
|
|
382
|
-
at: z.ZodNumber;
|
|
383
|
-
text: z.ZodOptional<z.ZodString>;
|
|
384
|
-
taskId: z.ZodOptional<z.ZodString>;
|
|
385
|
-
stage: z.ZodOptional<z.ZodEnum<{
|
|
386
|
-
accepted: "accepted";
|
|
387
|
-
relayed: "relayed";
|
|
388
|
-
delivered: "delivered";
|
|
389
|
-
held: "held";
|
|
390
|
-
handed_to_agent: "handed_to_agent";
|
|
391
|
-
read: "read";
|
|
392
|
-
replied: "replied";
|
|
393
|
-
rejected: "rejected";
|
|
394
|
-
expired: "expired";
|
|
395
|
-
}>>;
|
|
396
|
-
role: z.ZodOptional<z.ZodEnum<{
|
|
397
|
-
requester: "requester";
|
|
398
|
-
executor: "executor";
|
|
399
|
-
}>>;
|
|
400
|
-
state: z.ZodOptional<z.ZodEnum<{
|
|
401
|
-
TASK_STATE_SUBMITTED: "TASK_STATE_SUBMITTED";
|
|
402
|
-
TASK_STATE_WORKING: "TASK_STATE_WORKING";
|
|
403
|
-
TASK_STATE_COMPLETED: "TASK_STATE_COMPLETED";
|
|
404
|
-
TASK_STATE_FAILED: "TASK_STATE_FAILED";
|
|
405
|
-
TASK_STATE_CANCELED: "TASK_STATE_CANCELED";
|
|
406
|
-
TASK_STATE_INPUT_REQUIRED: "TASK_STATE_INPUT_REQUIRED";
|
|
407
|
-
TASK_STATE_REJECTED: "TASK_STATE_REJECTED";
|
|
408
|
-
TASK_STATE_AUTH_REQUIRED: "TASK_STATE_AUTH_REQUIRED";
|
|
409
|
-
}>>;
|
|
410
|
-
}, z.core.$strip>;
|
|
411
|
-
export type ConvEntry = z.infer<typeof ConvEntry>;
|