@openvtc/trust-tasks 0.28.23 → 0.28.24

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.
Files changed (100) hide show
  1. package/CHANGELOG.md +62 -0
  2. package/dist/_shared/components.d.ts +520 -0
  3. package/dist/_shared/components.d.ts.map +1 -1
  4. package/dist/index.d.ts +45 -0
  5. package/dist/index.d.ts.map +1 -1
  6. package/dist/index.js +45 -0
  7. package/dist/index.js.map +1 -1
  8. package/dist/messaging/mux/_shared/0.1/mux.d.ts +16 -0
  9. package/dist/messaging/mux/_shared/0.1/mux.d.ts.map +1 -0
  10. package/dist/messaging/mux/_shared/0.1/mux.js +6 -0
  11. package/dist/messaging/mux/_shared/0.1/mux.js.map +1 -0
  12. package/dist/messaging/mux/attach/0.1/payload.d.ts +996 -0
  13. package/dist/messaging/mux/attach/0.1/payload.d.ts.map +1 -0
  14. package/dist/messaging/mux/attach/0.1/payload.js +594 -0
  15. package/dist/messaging/mux/attach/0.1/payload.js.map +1 -0
  16. package/dist/messaging/mux/detach/0.1/payload.d.ts +398 -0
  17. package/dist/messaging/mux/detach/0.1/payload.d.ts.map +1 -0
  18. package/dist/messaging/mux/detach/0.1/payload.js +215 -0
  19. package/dist/messaging/mux/detach/0.1/payload.js.map +1 -0
  20. package/dist/messaging/mux/event/0.1/payload.d.ts +513 -0
  21. package/dist/messaging/mux/event/0.1/payload.d.ts.map +1 -0
  22. package/dist/messaging/mux/event/0.1/payload.js +260 -0
  23. package/dist/messaging/mux/event/0.1/payload.js.map +1 -0
  24. package/dist/messaging/mux/grant/0.1/payload.d.ts +1008 -0
  25. package/dist/messaging/mux/grant/0.1/payload.d.ts.map +1 -0
  26. package/dist/messaging/mux/grant/0.1/payload.js +606 -0
  27. package/dist/messaging/mux/grant/0.1/payload.js.map +1 -0
  28. package/dist/messaging/mux/list/0.1/payload.d.ts +1241 -0
  29. package/dist/messaging/mux/list/0.1/payload.d.ts.map +1 -0
  30. package/dist/messaging/mux/list/0.1/payload.js +715 -0
  31. package/dist/messaging/mux/list/0.1/payload.js.map +1 -0
  32. package/dist/messaging/mux/notice/0.1/payload.d.ts +489 -0
  33. package/dist/messaging/mux/notice/0.1/payload.d.ts.map +1 -0
  34. package/dist/messaging/mux/notice/0.1/payload.js +249 -0
  35. package/dist/messaging/mux/notice/0.1/payload.js.map +1 -0
  36. package/dist/messaging/mux/revoke/0.1/payload.d.ts +585 -0
  37. package/dist/messaging/mux/revoke/0.1/payload.d.ts.map +1 -0
  38. package/dist/messaging/mux/revoke/0.1/payload.js +311 -0
  39. package/dist/messaging/mux/revoke/0.1/payload.js.map +1 -0
  40. package/dist/messaging/mux/revoke-all/0.1/payload.d.ts +682 -0
  41. package/dist/messaging/mux/revoke-all/0.1/payload.d.ts.map +1 -0
  42. package/dist/messaging/mux/revoke-all/0.1/payload.js +397 -0
  43. package/dist/messaging/mux/revoke-all/0.1/payload.js.map +1 -0
  44. package/dist/messaging/mux/update/0.1/payload.d.ts +995 -0
  45. package/dist/messaging/mux/update/0.1/payload.d.ts.map +1 -0
  46. package/dist/messaging/mux/update/0.1/payload.js +586 -0
  47. package/dist/messaging/mux/update/0.1/payload.js.map +1 -0
  48. package/dist/vta/_shared/0.1/memory-record.d.ts +22 -0
  49. package/dist/vta/_shared/0.1/memory-record.d.ts.map +1 -0
  50. package/dist/vta/_shared/0.1/memory-record.js +6 -0
  51. package/dist/vta/_shared/0.1/memory-record.js.map +1 -0
  52. package/dist/vta/memory/delete/0.1/payload.d.ts +13 -2
  53. package/dist/vta/memory/delete/0.1/payload.d.ts.map +1 -1
  54. package/dist/vta/memory/delete/0.1/payload.js +1 -1
  55. package/dist/vta/memory/delete/0.1/payload.js.map +1 -1
  56. package/dist/vta/memory/delete/0.2/payload.d.ts +415 -0
  57. package/dist/vta/memory/delete/0.2/payload.d.ts.map +1 -0
  58. package/dist/vta/memory/delete/0.2/payload.js +224 -0
  59. package/dist/vta/memory/delete/0.2/payload.js.map +1 -0
  60. package/dist/vta/memory/get/0.1/payload.d.ts +646 -0
  61. package/dist/vta/memory/get/0.1/payload.d.ts.map +1 -0
  62. package/dist/vta/memory/get/0.1/payload.js +349 -0
  63. package/dist/vta/memory/get/0.1/payload.js.map +1 -0
  64. package/dist/vta/memory/list/0.1/payload.d.ts +13 -2
  65. package/dist/vta/memory/list/0.1/payload.d.ts.map +1 -1
  66. package/dist/vta/memory/list/0.1/payload.js +1 -1
  67. package/dist/vta/memory/list/0.1/payload.js.map +1 -1
  68. package/dist/vta/memory/list/0.2/payload.d.ts +693 -0
  69. package/dist/vta/memory/list/0.2/payload.d.ts.map +1 -0
  70. package/dist/vta/memory/list/0.2/payload.js +363 -0
  71. package/dist/vta/memory/list/0.2/payload.js.map +1 -0
  72. package/dist/vta/memory/put/0.1/payload.d.ts +13 -2
  73. package/dist/vta/memory/put/0.1/payload.d.ts.map +1 -1
  74. package/dist/vta/memory/put/0.1/payload.js +1 -1
  75. package/dist/vta/memory/put/0.1/payload.js.map +1 -1
  76. package/dist/vta/memory/put/0.2/payload.d.ts +490 -0
  77. package/dist/vta/memory/put/0.2/payload.d.ts.map +1 -0
  78. package/dist/vta/memory/put/0.2/payload.js +264 -0
  79. package/dist/vta/memory/put/0.2/payload.js.map +1 -0
  80. package/package.json +1 -1
  81. package/src/_shared/components.ts +581 -0
  82. package/src/index.ts +45 -0
  83. package/src/messaging/mux/_shared/0.1/mux.ts +17 -0
  84. package/src/messaging/mux/attach/0.1/payload.ts +682 -0
  85. package/src/messaging/mux/detach/0.1/payload.ts +278 -0
  86. package/src/messaging/mux/event/0.1/payload.ts +371 -0
  87. package/src/messaging/mux/grant/0.1/payload.ts +710 -0
  88. package/src/messaging/mux/list/0.1/payload.ts +793 -0
  89. package/src/messaging/mux/notice/0.1/payload.ts +362 -0
  90. package/src/messaging/mux/revoke/0.1/payload.ts +389 -0
  91. package/src/messaging/mux/revoke-all/0.1/payload.ts +452 -0
  92. package/src/messaging/mux/update/0.1/payload.ts +644 -0
  93. package/src/vta/_shared/0.1/memory-record.ts +23 -0
  94. package/src/vta/memory/delete/0.1/payload.ts +14 -3
  95. package/src/vta/memory/delete/0.2/payload.ts +288 -0
  96. package/src/vta/memory/get/0.1/payload.ts +414 -0
  97. package/src/vta/memory/list/0.1/payload.ts +14 -3
  98. package/src/vta/memory/list/0.2/payload.ts +445 -0
  99. package/src/vta/memory/put/0.1/payload.ts +14 -3
  100. package/src/vta/memory/put/0.2/payload.ts +333 -0
package/CHANGELOG.md CHANGED
@@ -11,6 +11,68 @@ The package versions over **its own API** — what a consumer compiles against
11
11
  not over `SPEC.md`. Below 1.0 a breaking change bumps the leading non-zero
12
12
  component.
13
13
 
14
+ ## 0.28.24 — 2026-11-09
15
+
16
+
17
+ ### Added
18
+
19
+ - **messaging/mux**: DID multiplexing at a mediator (messaging/mux/*/0.1) (#1068)
20
+
21
+ * feat(messaging/mux): DID multiplexing at a mediator (messaging/mux/*/0.1)
22
+
23
+ One authenticated connection (the principal) carries live delivery and
24
+ pickup for many member DIDs: session attaches bound to one connection's
25
+ sessionId/muxNonce, and stored grants a member DID signs once. Members
26
+ sign closed statements (muxAttach, muxGrant, muxRevokeAll) with an
27
+ embedded Data Integrity proof (proofPurpose authentication), verified in a
28
+ normative order before any state changes.
29
+
30
+ Adds attach, detach, grant, list, update (narrow only), revoke,
31
+ revoke-all (epoch advance), event (live: ready/attached/detached/refused,
32
+ incl. the tsp-mux subprotocol) and notice (durable: grantsSuspended,
33
+ grantsRevoked, grantsExpiring, grantsPresent), with shared definitions in
34
+ messaging/mux/_shared/0.1/mux.schema.json, stable per-statement refusal
35
+ codes, the unknown-key suspension rule and replay floors.
36
+
37
+ Allowlists eddsa-rdfc-2022 as W3C Data Integrity vocabulary for the
38
+ casing lint.
39
+
40
+ - **vta/memory**: Versioned writes, tombstones, a change feed and named reads (put/delete/list 0.2, get 0.1) (#1067)
41
+
42
+ vta/memory 0.1 is an unconditional upsert key/value store: put overwrites
43
+ with no version, so two writers clobber each other undetected; delete is a
44
+ hard delete, so another device's cached copy never learns the item is gone;
45
+ and list returns the whole context with no prefix, paging or change feed.
46
+
47
+ The new versions apply vta/app-state's semantics to memory, restated per
48
+ spec so each can be implemented on its own:
49
+
50
+ - A per-context write counter (`MemoryRecord.version`, in the new shared
51
+ definition vta/_shared/0.1/memory-record) serves both as the
52
+ optimistic-concurrency token and the sync watermark.
53
+ - put/0.2: optional `expectedVersion` (0 = create only). A failed
54
+ precondition is `versionConflict`, with the current version and value
55
+ in its details so the loser need not re-read. The response returns
56
+ `version`, `wasCreated`, `updatedAt` and `valueBytes`. `valueTooLarge`
57
+ carries `limitBytes` / `actualBytes`. `currentValue` is withheld from a
58
+ caller that may write the context but not read it.
59
+ - delete/0.2: leaves a tombstone, takes an optional positive
60
+ `expectedVersion`, and treats deleting nothing as success
61
+ (`existed: false`).
62
+ - list/0.2: a snapshot (prefix, cursor/limit, values by default as in
63
+ 0.1) or a change feed from `sinceVersion` that includes tombstones,
64
+ with `highWatermark`, `watermarkTooOld` and `cursorInvalid`.
65
+ - get/0.1 (new): up to 256 named keys, each answered once in `items`,
66
+ `missing` or `deferred`. It is the read whose audit can name exactly
67
+ which items an agent saw.
68
+
69
+ The 0.1 versions stay published and are not superseded; a VTA serving
70
+ both writes one store, and the 0.2 prose says how 0.1 writes and deletes
71
+ take versions and leave tombstones there.
72
+
73
+ Requested in OpenVTC/verifiable-trust-infrastructure#2115. The
74
+ item-level read audit in #2116 builds on get/0.1.
75
+
14
76
  ## 0.28.23 — 2026-11-09
15
77
 
16
78
 
@@ -629,6 +629,10 @@ export type DeliveryStatus = "delivered" | "duplicate" | "refused" | "queued" |
629
629
  * What the listed party is, for the directory.
630
630
  */
631
631
  export type Description = string;
632
+ /**
633
+ * Why a member left a connection, or why a stored grant did not attach on connect. `revokedByMember` / `revokedByPrincipal`: messaging/mux/revoke by that side. `epochBumped`: the member DID ran messaging/mux/revoke-all. `suspendedUnknownKey`: the unknown-key rule suspended the grant. `keyRotated`: the grant's signing key left the member DID's current authentication relationship (grant state `staleKey`). `expired`: the grant or attach reached its effective expiry. `accountBlocked`: the member's account was blocked. `superseded`: the member DID's own direct connection, or a newer connection of the same kind, now receives its live traffic; the member stays on this connection inactive. `admin`: an operator acted. `detachRequested`: the principal removed a session attach with messaging/mux/detach. `accountRemoved`: the member's account, or the principal's, was removed. `resolutionFailed`: the member DID could not be resolved when the grant was re-validated; the grant is not changed and is re-checked later.
634
+ */
635
+ export type DetachReason = "revokedByMember" | "revokedByPrincipal" | "epochBumped" | "suspendedUnknownKey" | "keyRotated" | "expired" | "accountBlocked" | "superseded" | "admin" | "detachRequested" | "accountRemoved" | "resolutionFailed";
632
636
  /**
633
637
  * Producer-supplied attestation at registration time, verifiable by the maintainer against the platform's attestation infrastructure. Tagged union over the discriminator `kind`.
634
638
  */
@@ -868,6 +872,14 @@ export type ForgeId_GitNsV0_1 = string;
868
872
  * An identifier the forge itself assigns — a repository id, a user or organisation id — carried as a string so a forge whose ids are not numbers needs no new version. GitHub, Forgejo and GitLab ids are decimal integers written as strings (`"812736451"`). Unlike a name, it survives renames and transfers, which is why rights and bindings are keyed by it.
869
873
  */
870
874
  export type ForgeId_GitNsV0_6 = string;
875
+ /**
876
+ * A grant's identifier, chosen by the member DID's signer and carried in its grant statement; a UUID is RECOMMENDED. A mediator refuses a grant whose identifier is already on the member DID's record.
877
+ */
878
+ export type GrantId = string;
879
+ /**
880
+ * A stored grant's state. `active`: valid; the member is attached whenever the principal is connected. `suspended`: the member DID proved control with a key that signed none of its active grants (the unknown-key rule); terminal — the grant cannot be resumed and must be recreated by a fresh member signature. `staleKey`: the key that signed the grant is no longer in the member DID's current authentication relationship; terminal — it does not become active again if the key reappears. `expired`: an active grant past its effective expiry; computed when read, never stored. `epochRevoked`: the member DID advanced its epoch with messaging/mux/revoke-all. A grant revoked with messaging/mux/revoke has no state: it is deleted. A dead grant (every state but `active`) stays listable for the mediator's retention window after its effective expiry, then is pruned.
881
+ */
882
+ export type GrantState = "active" | "suspended" | "staleKey" | "expired" | "epochRevoked";
871
883
  /**
872
884
  * Validity of a grant the sweep issues, in seconds: between one day and two years, the bounds vtc/vetting/vetters/grant applies to an administrator's grants.
873
885
  */
@@ -1095,6 +1107,10 @@ export type MemberAction = "read" | "write" | "curate";
1095
1107
  * @maxItems 3
1096
1108
  */
1097
1109
  export type MemberActions = [MemberAction] | [MemberAction, MemberAction] | [MemberAction, MemberAction, MemberAction];
1110
+ /**
1111
+ * The reason carried by one member's change in a messaging/mux/event `attached` or `detached` event: exactly the AttachReason values followed by the DetachReason values, with their meanings. An `attached` event carries only AttachReason values and a `detached` event only DetachReason values. One closed set rather than a union, so every generated binding types it as one enumeration; it MUST be kept equal to the two sets it joins.
1112
+ */
1113
+ export type MemberChangeReason = "connect" | "grant" | "attach" | "reactivated" | "revokedByMember" | "revokedByPrincipal" | "epochBumped" | "suspendedUnknownKey" | "keyRotated" | "expired" | "accountBlocked" | "superseded" | "admin" | "detachRequested" | "accountRemoved" | "resolutionFailed";
1098
1114
  /**
1099
1115
  * Where an admission stands. `offered`: credentials issued and waiting for the member to collect and accept them. `admitted`: accepted — on a sealed tier, the member is in the room's group. `removed`: an administrator removed them; on a sealed tier the room has advanced past them.
1100
1116
  */
@@ -1111,6 +1127,22 @@ export type MembersOnly = boolean;
1111
1127
  * How the member came to be in the group. `added`: by a manager. `joined`: they joined an open group. `requestApproved`: a manager approved their request. `rule`: a dynamic group's rule admits them.
1112
1128
  */
1113
1129
  export type MembershipSource = "added" | "joined" | "requestApproved" | "rule";
1130
+ /**
1131
+ * Optimistic-concurrency precondition on a write. A positive value requires that the item's current `version` equals it exactly. Zero means "create only" — the write applies only if no LIVE item exists at the key. A tombstone is not a live item, so `expectedVersion: 0` succeeds over one; the created item takes the context's next counter value, which is necessarily greater than the tombstone's.
1132
+ */
1133
+ export type MemoryExpectedVersion = number;
1134
+ /**
1135
+ * Agent-chosen identifier for an item within a context. Opaque to the maintainer: it MUST NOT be parsed, normalized, or case-folded, and prefix matching in `vta/memory/list` is a byte-prefix comparison over the UTF-8 encoding. Agents SHOULD use `/`-delimited hierarchical keys (`contact/billing`, `preference/timezone`) so that `prefix` can address a family of items, but the delimiter is a convention between an agent and itself. A key is content as well as an address: a key naming a person, a condition or a dispute discloses something to anyone who can list the context, even without its value.
1136
+ */
1137
+ export type MemoryKey = string;
1138
+ /**
1139
+ * The remembered text: a fact, a summary, a preference. Opaque to the maintainer, which stores it as given and never interprets, rewrites or summarises it. The maintainer enforces a documented per-item cap on its size (see `vta/memory/put`).
1140
+ */
1141
+ export type MemoryValue = string;
1142
+ /**
1143
+ * A value of the context's monotonic write counter (see this schema's description). Server-assigned; a producer never chooses one.
1144
+ */
1145
+ export type MemoryVersion = number;
1114
1146
  /**
1115
1147
  * An RFC 9162 audit or consistency path: the node hashes, in the order §2.1.3 / §2.1.4 define.
1116
1148
  *
@@ -1141,6 +1173,146 @@ export type Multibase_VotingV0_1 = string;
1141
1173
  * A binary value, multibase base58btc over the suite's canonical encoding.
1142
1174
  */
1143
1175
  export type Multibase_VtaV0_4 = string;
1176
+ /**
1177
+ * A DID, carried verbatim and compared by exact string equality. Unlike the messaging family's `Vid`, never a hash: the mediator resolves it to verify a statement signed by it. For a member DID reached over TSP, the TSP VID is the DID itself.
1178
+ */
1179
+ export type MuxDid = string;
1180
+ /**
1181
+ * 32 random bytes, base64url without padding, that belong to exactly one connection and are never reused. Attach statements sign over it, which is what makes an attach statement unusable on any other connection.
1182
+ */
1183
+ export type MuxNonce = string;
1184
+ /**
1185
+ * The side of a delegation a requester acts as. `principal`: the DID that authenticated the connection and to which members' traffic is delegated. `member`: a DID whose traffic is delegated.
1186
+ */
1187
+ export type MuxRole = "principal" | "member";
1188
+ /**
1189
+ * A set of capabilities: a non-empty JSON array of MuxScopeValue, compared as a set — order is not significant and a repeated value collapses into one. Never empty: an empty scope is refused, never read as "all". There is no default scope anywhere — every attach and every grant names its scope explicitly. A scope is always bounded by the member DID's own access-control capabilities at the mediator.
1190
+ *
1191
+ * @minItems 1
1192
+ * @maxItems 16
1193
+ */
1194
+ export type MuxScope = [MuxScopeValue] | [MuxScopeValue, MuxScopeValue] | [MuxScopeValue, MuxScopeValue, MuxScopeValue] | [MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue] | [MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue] | [MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue] | [MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue] | [
1195
+ MuxScopeValue,
1196
+ MuxScopeValue,
1197
+ MuxScopeValue,
1198
+ MuxScopeValue,
1199
+ MuxScopeValue,
1200
+ MuxScopeValue,
1201
+ MuxScopeValue,
1202
+ MuxScopeValue
1203
+ ] | [
1204
+ MuxScopeValue,
1205
+ MuxScopeValue,
1206
+ MuxScopeValue,
1207
+ MuxScopeValue,
1208
+ MuxScopeValue,
1209
+ MuxScopeValue,
1210
+ MuxScopeValue,
1211
+ MuxScopeValue,
1212
+ MuxScopeValue
1213
+ ] | [
1214
+ MuxScopeValue,
1215
+ MuxScopeValue,
1216
+ MuxScopeValue,
1217
+ MuxScopeValue,
1218
+ MuxScopeValue,
1219
+ MuxScopeValue,
1220
+ MuxScopeValue,
1221
+ MuxScopeValue,
1222
+ MuxScopeValue,
1223
+ MuxScopeValue
1224
+ ] | [
1225
+ MuxScopeValue,
1226
+ MuxScopeValue,
1227
+ MuxScopeValue,
1228
+ MuxScopeValue,
1229
+ MuxScopeValue,
1230
+ MuxScopeValue,
1231
+ MuxScopeValue,
1232
+ MuxScopeValue,
1233
+ MuxScopeValue,
1234
+ MuxScopeValue,
1235
+ MuxScopeValue
1236
+ ] | [
1237
+ MuxScopeValue,
1238
+ MuxScopeValue,
1239
+ MuxScopeValue,
1240
+ MuxScopeValue,
1241
+ MuxScopeValue,
1242
+ MuxScopeValue,
1243
+ MuxScopeValue,
1244
+ MuxScopeValue,
1245
+ MuxScopeValue,
1246
+ MuxScopeValue,
1247
+ MuxScopeValue,
1248
+ MuxScopeValue
1249
+ ] | [
1250
+ MuxScopeValue,
1251
+ MuxScopeValue,
1252
+ MuxScopeValue,
1253
+ MuxScopeValue,
1254
+ MuxScopeValue,
1255
+ MuxScopeValue,
1256
+ MuxScopeValue,
1257
+ MuxScopeValue,
1258
+ MuxScopeValue,
1259
+ MuxScopeValue,
1260
+ MuxScopeValue,
1261
+ MuxScopeValue,
1262
+ MuxScopeValue
1263
+ ] | [
1264
+ MuxScopeValue,
1265
+ MuxScopeValue,
1266
+ MuxScopeValue,
1267
+ MuxScopeValue,
1268
+ MuxScopeValue,
1269
+ MuxScopeValue,
1270
+ MuxScopeValue,
1271
+ MuxScopeValue,
1272
+ MuxScopeValue,
1273
+ MuxScopeValue,
1274
+ MuxScopeValue,
1275
+ MuxScopeValue,
1276
+ MuxScopeValue,
1277
+ MuxScopeValue
1278
+ ] | [
1279
+ MuxScopeValue,
1280
+ MuxScopeValue,
1281
+ MuxScopeValue,
1282
+ MuxScopeValue,
1283
+ MuxScopeValue,
1284
+ MuxScopeValue,
1285
+ MuxScopeValue,
1286
+ MuxScopeValue,
1287
+ MuxScopeValue,
1288
+ MuxScopeValue,
1289
+ MuxScopeValue,
1290
+ MuxScopeValue,
1291
+ MuxScopeValue,
1292
+ MuxScopeValue,
1293
+ MuxScopeValue
1294
+ ] | [
1295
+ MuxScopeValue,
1296
+ MuxScopeValue,
1297
+ MuxScopeValue,
1298
+ MuxScopeValue,
1299
+ MuxScopeValue,
1300
+ MuxScopeValue,
1301
+ MuxScopeValue,
1302
+ MuxScopeValue,
1303
+ MuxScopeValue,
1304
+ MuxScopeValue,
1305
+ MuxScopeValue,
1306
+ MuxScopeValue,
1307
+ MuxScopeValue,
1308
+ MuxScopeValue,
1309
+ MuxScopeValue,
1310
+ MuxScopeValue
1311
+ ];
1312
+ /**
1313
+ * One capability a member DID extends to a principal's connection. `receive`: live delivery of the member's inbound messages on the connection. `pickup`: message-pickup status and delivery requests naming the member as `recipient_did`, and inclusion in a raw-TSP inbox drain. `delete`: deleting the member's stored messages, including delete-on-ack and delete-on-send; a member without `delete` keeps its messages in its inbox until something holding `delete` collects them. `send`: the mediator accepts on this connection frames whose sender is the member DID — the frame is still signed or authcrypted with the member's own keys; the scope only lets the mediator accept it on this socket.
1314
+ */
1315
+ export type MuxScopeValue = "receive" | "pickup" | "delete" | "send";
1144
1316
  /**
1145
1317
  * Scopes one application's records within a context, so several tools can share a context without colliding — `openvtc`, `cnm`, an agent runtime. The maintainer MUST NOT interpret the value; it is an opaque partition name. Namespaces are first-come and unreserved, so an application SHOULD pick a stable, specific one: a future per-namespace ACL would grant on this exact string, which makes renaming a namespace a migration rather than an edit.
1146
1318
  */
@@ -1856,6 +2028,10 @@ export type ServiceKind = "didcomm" | "rest" | "tsp" | "webauthn";
1856
2028
  * The id of the witness/session document the VTA built in vta/witness/open: the session's name, the thread every document of the session is on, and the value the VWC carries as taskContext. The VTA keys its state for the session by it.
1857
2029
  */
1858
2030
  export type SessionId = string;
2031
+ /**
2032
+ * The mediator's identifier for one authenticated connection, as announced in that connection's `ready` event.
2033
+ */
2034
+ export type SessionId_MessagingMuxV0_1 = string;
1859
2035
  /**
1860
2036
  * `EdDSA` pairs with an `ed25519` key; `ES256` pairs with a `p256` key; `ML-DSA-44` and `ML-DSA-65` pair with `mldsa44` and `mldsa65` keys respectively. An `x25519` key performs key agreement and can sign nothing, so no algorithm here is valid for one. These are JOSE algorithm identifiers, externally owned, so they are carried verbatim and never re-cased (SPEC.md §4.10 rule 5); the ML-DSA names are those RFC 9964 registers in the JOSE Web Signature and Encryption Algorithms registry, which is why their hyphenated casing differs from the `keyType` values beside them — those are specification-defined. The set is expected to grow as algorithms are registered. The enumeration remains closed: an unrecognised algorithm is refused rather than silently substituted with a supported one.
1861
2037
  */
@@ -1899,6 +2075,129 @@ export type Slot = string;
1899
2075
  * The principal's disposition of a held notification: `active`, or `dismissed` by vta/notifications/dismiss. Dismissal is the principal's alone and changes nothing outside the VTA (VTI-NTF-052).
1900
2076
  */
1901
2077
  export type State = "active" | "dismissed";
2078
+ /**
2079
+ * The scope a member DID signs into a statement: a JSON array of MuxScopeValue, compared as a set — order is not significant and a repeated value collapses. It MUST NOT be empty; an empty signed scope is refused with the task's `emptyScope` code, never read as "all". Unlike MuxScope, emptiness is not a schema failure here, so that the refusal is reported per statement rather than failing the whole batch.
2080
+ *
2081
+ * @maxItems 16
2082
+ */
2083
+ export type StatementScope = [] | [MuxScopeValue] | [MuxScopeValue, MuxScopeValue] | [MuxScopeValue, MuxScopeValue, MuxScopeValue] | [MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue] | [MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue] | [MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue] | [MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue, MuxScopeValue] | [
2084
+ MuxScopeValue,
2085
+ MuxScopeValue,
2086
+ MuxScopeValue,
2087
+ MuxScopeValue,
2088
+ MuxScopeValue,
2089
+ MuxScopeValue,
2090
+ MuxScopeValue,
2091
+ MuxScopeValue
2092
+ ] | [
2093
+ MuxScopeValue,
2094
+ MuxScopeValue,
2095
+ MuxScopeValue,
2096
+ MuxScopeValue,
2097
+ MuxScopeValue,
2098
+ MuxScopeValue,
2099
+ MuxScopeValue,
2100
+ MuxScopeValue,
2101
+ MuxScopeValue
2102
+ ] | [
2103
+ MuxScopeValue,
2104
+ MuxScopeValue,
2105
+ MuxScopeValue,
2106
+ MuxScopeValue,
2107
+ MuxScopeValue,
2108
+ MuxScopeValue,
2109
+ MuxScopeValue,
2110
+ MuxScopeValue,
2111
+ MuxScopeValue,
2112
+ MuxScopeValue
2113
+ ] | [
2114
+ MuxScopeValue,
2115
+ MuxScopeValue,
2116
+ MuxScopeValue,
2117
+ MuxScopeValue,
2118
+ MuxScopeValue,
2119
+ MuxScopeValue,
2120
+ MuxScopeValue,
2121
+ MuxScopeValue,
2122
+ MuxScopeValue,
2123
+ MuxScopeValue,
2124
+ MuxScopeValue
2125
+ ] | [
2126
+ MuxScopeValue,
2127
+ MuxScopeValue,
2128
+ MuxScopeValue,
2129
+ MuxScopeValue,
2130
+ MuxScopeValue,
2131
+ MuxScopeValue,
2132
+ MuxScopeValue,
2133
+ MuxScopeValue,
2134
+ MuxScopeValue,
2135
+ MuxScopeValue,
2136
+ MuxScopeValue,
2137
+ MuxScopeValue
2138
+ ] | [
2139
+ MuxScopeValue,
2140
+ MuxScopeValue,
2141
+ MuxScopeValue,
2142
+ MuxScopeValue,
2143
+ MuxScopeValue,
2144
+ MuxScopeValue,
2145
+ MuxScopeValue,
2146
+ MuxScopeValue,
2147
+ MuxScopeValue,
2148
+ MuxScopeValue,
2149
+ MuxScopeValue,
2150
+ MuxScopeValue,
2151
+ MuxScopeValue
2152
+ ] | [
2153
+ MuxScopeValue,
2154
+ MuxScopeValue,
2155
+ MuxScopeValue,
2156
+ MuxScopeValue,
2157
+ MuxScopeValue,
2158
+ MuxScopeValue,
2159
+ MuxScopeValue,
2160
+ MuxScopeValue,
2161
+ MuxScopeValue,
2162
+ MuxScopeValue,
2163
+ MuxScopeValue,
2164
+ MuxScopeValue,
2165
+ MuxScopeValue,
2166
+ MuxScopeValue
2167
+ ] | [
2168
+ MuxScopeValue,
2169
+ MuxScopeValue,
2170
+ MuxScopeValue,
2171
+ MuxScopeValue,
2172
+ MuxScopeValue,
2173
+ MuxScopeValue,
2174
+ MuxScopeValue,
2175
+ MuxScopeValue,
2176
+ MuxScopeValue,
2177
+ MuxScopeValue,
2178
+ MuxScopeValue,
2179
+ MuxScopeValue,
2180
+ MuxScopeValue,
2181
+ MuxScopeValue,
2182
+ MuxScopeValue
2183
+ ] | [
2184
+ MuxScopeValue,
2185
+ MuxScopeValue,
2186
+ MuxScopeValue,
2187
+ MuxScopeValue,
2188
+ MuxScopeValue,
2189
+ MuxScopeValue,
2190
+ MuxScopeValue,
2191
+ MuxScopeValue,
2192
+ MuxScopeValue,
2193
+ MuxScopeValue,
2194
+ MuxScopeValue,
2195
+ MuxScopeValue,
2196
+ MuxScopeValue,
2197
+ MuxScopeValue,
2198
+ MuxScopeValue,
2199
+ MuxScopeValue
2200
+ ];
1902
2201
  /**
1903
2202
  * Whether the thing is still open to the audience: `available`, or `withdrawn` — cancelled by its holder, or no longer open to the audience — in which case the recipient keeps the record only to show that it was withdrawn (VTI-NTF-024).
1904
2203
  */
@@ -5196,6 +5495,57 @@ export interface ApproverBinding {
5196
5495
  */
5197
5496
  routeHint?: string;
5198
5497
  }
5498
+ /**
5499
+ * A member DID's statement that the named principal may carry its traffic on one connection — the one whose `sessionId` and `muxNonce` it names — until `exp`, within `scope`. Signed by the member with an embedded Data Integrity proof whose purpose is `authentication`.
5500
+ */
5501
+ export interface AttachStatement {
5502
+ /**
5503
+ * Always `muxAttach`; names the statement kind, so a statement of one kind is never accepted as another.
5504
+ */
5505
+ type: "muxAttach";
5506
+ /**
5507
+ * The member DID: the signer, and the DID the statement concerns.
5508
+ */
5509
+ issuer: MuxDid;
5510
+ /**
5511
+ * The mediator's DID. A statement names exactly one mediator and is refused by every other.
5512
+ */
5513
+ audience: MuxDid;
5514
+ /**
5515
+ * The principal DID the connection is authenticated as. MUST differ from `issuer`.
5516
+ */
5517
+ principal: MuxDid;
5518
+ sessionId: SessionId_MessagingMuxV0_1;
5519
+ muxNonce: MuxNonce;
5520
+ scope: StatementScope;
5521
+ /**
5522
+ * JWT NumericDate (RFC 7519 §2), whole seconds since 1970-01-01T00:00:00Z UTC: when the statement was signed. MUST NOT be more than 60 seconds in the mediator's future.
5523
+ */
5524
+ iat: number;
5525
+ /**
5526
+ * JWT NumericDate (RFC 7519 §2): when the statement stops being accepted. REQUIRED; MUST be after `iat` and in the future.
5527
+ */
5528
+ exp: number;
5529
+ proof: MuxDataIntegrityProof;
5530
+ }
5531
+ /**
5532
+ * One session attach on a connection.
5533
+ */
5534
+ export interface AttachView {
5535
+ /**
5536
+ * The member DID.
5537
+ */
5538
+ did: MuxDid;
5539
+ scope: MuxScope;
5540
+ /**
5541
+ * When the attach lapses: its signed `exp`.
5542
+ */
5543
+ expiresAt: string;
5544
+ /**
5545
+ * False while live traffic for the member goes elsewhere — to the member DID's own direct connection, which takes precedence over a mux connection.
5546
+ */
5547
+ deliveryActive: boolean;
5548
+ }
5199
5549
  export interface AttachmentRef_VaultV0_1 {
5200
5550
  /**
5201
5551
  * Opaque maintainer-assigned id for this attachment; used to fetch the blob via a separate mechanism.
@@ -9474,6 +9824,82 @@ export interface GitNamespace_GitNsV0_6 {
9474
9824
  */
9475
9825
  state: "pending" | "bound";
9476
9826
  }
9827
+ /**
9828
+ * Identifies one stored grant and the two parties to it.
9829
+ */
9830
+ export interface GrantRef {
9831
+ grantId: GrantId;
9832
+ /**
9833
+ * The member DID.
9834
+ */
9835
+ did: MuxDid;
9836
+ /**
9837
+ * The principal DID the grant delegates to.
9838
+ */
9839
+ principal: MuxDid;
9840
+ }
9841
+ /**
9842
+ * A member DID's standing statement that the named principal may carry its traffic at this mediator, on any connection, until `exp`, within `scope`, under the member's current `epoch`. Signed by the member with an embedded Data Integrity proof whose purpose is `authentication`, and stored verbatim by the mediator as the only evidence of the delegation.
9843
+ */
9844
+ export interface GrantStatement {
9845
+ /**
9846
+ * Always `muxGrant`; names the statement kind, so a statement of one kind is never accepted as another.
9847
+ */
9848
+ type: "muxGrant";
9849
+ /**
9850
+ * The member DID: the signer, and the DID the statement concerns.
9851
+ */
9852
+ issuer: MuxDid;
9853
+ /**
9854
+ * The mediator's DID. A statement names exactly one mediator and is refused by every other.
9855
+ */
9856
+ audience: MuxDid;
9857
+ grantId: GrantId;
9858
+ /**
9859
+ * The principal DID that may carry the member's traffic. MUST differ from `issuer`.
9860
+ */
9861
+ principal: MuxDid;
9862
+ scope: StatementScope;
9863
+ /**
9864
+ * The member DID's current epoch at the mediator. Only messaging/mux/revoke-all advances it.
9865
+ */
9866
+ epoch: number;
9867
+ /**
9868
+ * JWT NumericDate (RFC 7519 §2), whole seconds since 1970-01-01T00:00:00Z UTC: when the statement was signed. MUST NOT be more than 60 seconds in the mediator's future.
9869
+ */
9870
+ iat: number;
9871
+ /**
9872
+ * JWT NumericDate (RFC 7519 §2): when the statement stops being accepted. REQUIRED; MUST be after `iat` and in the future.
9873
+ */
9874
+ exp: number;
9875
+ proof: MuxDataIntegrityProof;
9876
+ }
9877
+ /**
9878
+ * The mediator's view of one stored grant, as messaging/mux/list and messaging/mux/update return it: the grant statement verbatim, with the state and the effective scope and expiry beside it.
9879
+ */
9880
+ export interface GrantView {
9881
+ /**
9882
+ * The grant statement exactly as the member signed it and the mediator stored it, proof included, so either party can re-verify it.
9883
+ */
9884
+ statement: GrantStatement;
9885
+ state: GrantState;
9886
+ /**
9887
+ * The effective scope: the signed scope, or the narrower one messaging/mux/update set.
9888
+ */
9889
+ scope: MuxScope;
9890
+ /**
9891
+ * The effective expiry: the signed `exp` rendered as RFC 3339, or the earlier one messaging/mux/update set.
9892
+ */
9893
+ expiresAt: string;
9894
+ /**
9895
+ * True when messaging/mux/update narrowed the effective scope or expiry below what the statement signs.
9896
+ */
9897
+ narrowed?: boolean;
9898
+ /**
9899
+ * Principal view only: whether the member is attached through this grant to the connection that carried the list request.
9900
+ */
9901
+ attachedNow?: boolean;
9902
+ }
9477
9903
  /**
9478
9904
  * A grant set the group confers: each capability is written onto every member's access-control entry as a resource grant whose source is the group, bounded by the member's role ceiling and by the binder's own holdings.
9479
9905
  */
@@ -10894,6 +11320,44 @@ export interface MemberResponse {
10894
11320
  */
10895
11321
  export interface Membership {
10896
11322
  }
11323
+ /**
11324
+ * A memory item as the maintainer holds it. `value` is absent in two distinct situations and a consumer MUST NOT conflate them: the item is a tombstone (`deleted` is true), or the caller asked for a metadata-only view (`vta/memory/list` without `includeValues`). This is why `deleted` is required rather than defaulted — a consumer that infers deletion from an absent value gets the tombstone case wrong exactly when convergence depends on it.
11325
+ */
11326
+ export interface MemoryRecord {
11327
+ /**
11328
+ * The VTA context the item is scoped to; the isolation boundary.
11329
+ */
11330
+ contextId: string;
11331
+ key: MemoryKey;
11332
+ /**
11333
+ * The context counter value this item's most recent write took. Supply it as `expectedVersion` on the next write to make that write conditional on nothing having changed in between.
11334
+ */
11335
+ version: MemoryVersion;
11336
+ /**
11337
+ * The remembered text. Absent when this is a tombstone or a metadata-only view.
11338
+ */
11339
+ value?: MemoryValue;
11340
+ /**
11341
+ * Size of the stored value in bytes over its UTF-8 encoding, as the maintainer measures it for the per-item cap. Present in metadata-only views so a consumer can decide what to fetch without fetching it; absent on a tombstone.
11342
+ */
11343
+ valueBytes?: number;
11344
+ /**
11345
+ * True when this is a tombstone: the item was deleted, and this entry exists so that a consumer syncing incrementally learns of the deletion. Tombstones are reaped after the maintainer's retention window; see `vta/memory/list`.
11346
+ */
11347
+ deleted: boolean;
11348
+ /**
11349
+ * When the item was first created at this key. MAY be absent on a tombstone whose body has been discarded, and on an item written before the maintainer kept versions.
11350
+ */
11351
+ createdAt?: string;
11352
+ /**
11353
+ * When the write that produced this `version` was applied. For a tombstone, when the delete was applied.
11354
+ */
11355
+ updatedAt: string;
11356
+ /**
11357
+ * When the item was deleted. Present only when `deleted` is true; equal to `updatedAt` for a tombstone the maintainer has not since rewritten.
11358
+ */
11359
+ deletedAt?: string;
11360
+ }
10897
11361
  /**
10898
11362
  * Metadata of one stored message. Never carries the message body.
10899
11363
  */
@@ -11200,6 +11664,32 @@ export interface MonitorFilter {
11200
11664
  */
11201
11665
  failuresOnly?: boolean;
11202
11666
  }
11667
+ /**
11668
+ * The W3C Data Integrity proof embedded in a mux statement, made by the member DID: the format and verifier Trust Tasks already use for document proofs (SPEC §4.7). The proof covers the whole statement except `proof` itself, as the cryptosuite defines. Closed: a member Data Integrity defines but this list omits is refused.
11669
+ */
11670
+ export interface MuxDataIntegrityProof {
11671
+ type: "DataIntegrityProof";
11672
+ /**
11673
+ * The W3C Data Integrity EdDSA cryptosuite used.
11674
+ */
11675
+ cryptosuite: "eddsa-jcs-2022" | "eddsa-rdfc-2022";
11676
+ /**
11677
+ * The DID URL of the verification method that signed. MUST be controlled by the statement's `issuer` and listed in that DID's current `authentication` relationship.
11678
+ */
11679
+ verificationMethod: string;
11680
+ /**
11681
+ * MUST be `authentication`. Any other value is refused with `messaging/mux:proofPurposeInvalid` — a proof made for another relationship (an `assertionMethod` credential signature, say) is never accepted as control of the DID.
11682
+ */
11683
+ proofPurpose: string;
11684
+ /**
11685
+ * OPTIONAL: when the proof was made, as Data Integrity defines it. Covered by the proof; the statement's own `iat` is what the mediator checks.
11686
+ */
11687
+ created?: string;
11688
+ /**
11689
+ * The multibase (base58btc) signature.
11690
+ */
11691
+ proofValue: string;
11692
+ }
11203
11693
  /**
11204
11694
  * A badge as its holder sees it in their own list: the wall entry plus what only the holder knows — whether they hid it, their position for it, and the credential that evidences it.
11205
11695
  */
@@ -13206,6 +13696,36 @@ export interface RevocationReceipt {
13206
13696
  */
13207
13697
  revokedAt: string;
13208
13698
  }
13699
+ /**
13700
+ * A member DID's statement, proving current control of it, that every grant on it signed under `epoch` or earlier is void. Signed by the member with an embedded Data Integrity proof whose purpose is `authentication`.
13701
+ */
13702
+ export interface RevokeAllStatement {
13703
+ /**
13704
+ * Always `muxRevokeAll`; names the statement kind, so a statement of one kind is never accepted as another.
13705
+ */
13706
+ type: "muxRevokeAll";
13707
+ /**
13708
+ * The member DID: the signer, and the DID the statement concerns.
13709
+ */
13710
+ issuer: MuxDid;
13711
+ /**
13712
+ * The mediator's DID. A statement names exactly one mediator and is refused by every other.
13713
+ */
13714
+ audience: MuxDid;
13715
+ /**
13716
+ * The epoch being voided: the member DID's current one.
13717
+ */
13718
+ epoch: number;
13719
+ /**
13720
+ * JWT NumericDate (RFC 7519 §2), whole seconds since 1970-01-01T00:00:00Z UTC: when the statement was signed. MUST NOT be more than 60 seconds in the mediator's future.
13721
+ */
13722
+ iat: number;
13723
+ /**
13724
+ * JWT NumericDate (RFC 7519 §2): when the statement stops being accepted. REQUIRED; MUST be after `iat` and in the future.
13725
+ */
13726
+ exp: number;
13727
+ proof: MuxDataIntegrityProof;
13728
+ }
13209
13729
  /**
13210
13730
  * One recorded right. Implied rights (§4.2 of the rights model: `own` implies `maintain` implies `commit.sign` on the same resource; `ns.admin` implies `repo.create` and `own` across its namespace) are not records and never appear as RightRecords.
13211
13731
  */