sealbridge 0.0.1 → 0.1.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.
Files changed (187) hide show
  1. package/NOTICE +43 -0
  2. package/README.ja.md +375 -0
  3. package/README.md +466 -1
  4. package/dist/cli/dist/acp.d.ts +2 -0
  5. package/dist/cli/dist/acp.js +6 -0
  6. package/dist/cli/dist/acp.js.map +1 -0
  7. package/dist/cli/dist/board.d.ts +47 -0
  8. package/dist/cli/dist/board.js +255 -0
  9. package/dist/cli/dist/board.js.map +1 -0
  10. package/dist/cli/dist/contacts.d.ts +18 -0
  11. package/dist/cli/dist/contacts.js +154 -0
  12. package/dist/cli/dist/contacts.js.map +1 -0
  13. package/dist/cli/dist/doctor.d.ts +13 -0
  14. package/dist/cli/dist/doctor.js +30 -0
  15. package/dist/cli/dist/doctor.js.map +1 -0
  16. package/dist/cli/dist/index.d.ts +2 -0
  17. package/dist/cli/dist/index.js +193 -0
  18. package/dist/cli/dist/index.js.map +1 -0
  19. package/dist/cli/dist/invite-share.d.ts +16 -0
  20. package/dist/cli/dist/invite-share.js +169 -0
  21. package/dist/cli/dist/invite-share.js.map +1 -0
  22. package/dist/cli/dist/mcp.d.ts +17 -0
  23. package/dist/cli/dist/mcp.js +105 -0
  24. package/dist/cli/dist/mcp.js.map +1 -0
  25. package/dist/cli/dist/network.d.ts +1 -0
  26. package/dist/cli/dist/network.js +320 -0
  27. package/dist/cli/dist/network.js.map +1 -0
  28. package/dist/cli/dist/public-settings.d.ts +27 -0
  29. package/dist/cli/dist/public-settings.js +33 -0
  30. package/dist/cli/dist/public-settings.js.map +1 -0
  31. package/dist/cli/dist/receipt.d.ts +39 -0
  32. package/dist/cli/dist/receipt.js +90 -0
  33. package/dist/cli/dist/receipt.js.map +1 -0
  34. package/dist/cli/dist/receive-hook.d.ts +2 -0
  35. package/dist/cli/dist/receive-hook.js +35 -0
  36. package/dist/cli/dist/receive-hook.js.map +1 -0
  37. package/dist/examples/two-owner-demo/alice-policy.json +4 -0
  38. package/dist/examples/two-owner-demo/bob-policy.json +4 -0
  39. package/dist/examples/two-owner-demo/dist/run-demo.d.ts +71 -0
  40. package/dist/examples/two-owner-demo/dist/run-demo.js +383 -0
  41. package/dist/examples/two-owner-demo/dist/run-demo.js.map +1 -0
  42. package/dist/package.json +1 -0
  43. package/dist/packages/adapters/dist/command.d.ts +120 -0
  44. package/dist/packages/adapters/dist/command.js +365 -0
  45. package/dist/packages/adapters/dist/command.js.map +1 -0
  46. package/dist/packages/adapters/dist/credential-proxy.d.ts +37 -0
  47. package/dist/packages/adapters/dist/credential-proxy.js +363 -0
  48. package/dist/packages/adapters/dist/credential-proxy.js.map +1 -0
  49. package/dist/packages/adapters/dist/index.d.ts +6 -0
  50. package/dist/packages/adapters/dist/index.js +6 -0
  51. package/dist/packages/adapters/dist/index.js.map +1 -0
  52. package/dist/packages/adapters/dist/mcp.d.ts +32 -0
  53. package/dist/packages/adapters/dist/mcp.js +87 -0
  54. package/dist/packages/adapters/dist/mcp.js.map +1 -0
  55. package/dist/packages/adapters/dist/openai.d.ts +23 -0
  56. package/dist/packages/adapters/dist/openai.js +81 -0
  57. package/dist/packages/adapters/dist/openai.js.map +1 -0
  58. package/dist/packages/adapters/dist/sandbox.d.ts +45 -0
  59. package/dist/packages/adapters/dist/sandbox.js +60 -0
  60. package/dist/packages/adapters/dist/sandbox.js.map +1 -0
  61. package/dist/packages/core/dist/capability.d.ts +36 -0
  62. package/dist/packages/core/dist/capability.js +198 -0
  63. package/dist/packages/core/dist/capability.js.map +1 -0
  64. package/dist/packages/core/dist/contract.d.ts +33 -0
  65. package/dist/packages/core/dist/contract.js +97 -0
  66. package/dist/packages/core/dist/contract.js.map +1 -0
  67. package/dist/packages/core/dist/crypto.d.ts +34 -0
  68. package/dist/packages/core/dist/crypto.js +323 -0
  69. package/dist/packages/core/dist/crypto.js.map +1 -0
  70. package/dist/packages/core/dist/discovery.d.ts +124 -0
  71. package/dist/packages/core/dist/discovery.js +511 -0
  72. package/dist/packages/core/dist/discovery.js.map +1 -0
  73. package/dist/packages/core/dist/edge.d.ts +4 -0
  74. package/dist/packages/core/dist/edge.js +6 -0
  75. package/dist/packages/core/dist/edge.js.map +1 -0
  76. package/dist/packages/core/dist/index.d.ts +9 -0
  77. package/dist/packages/core/dist/index.js +10 -0
  78. package/dist/packages/core/dist/index.js.map +1 -0
  79. package/dist/packages/core/dist/receipts.d.ts +9 -0
  80. package/dist/packages/core/dist/receipts.js +67 -0
  81. package/dist/packages/core/dist/receipts.js.map +1 -0
  82. package/dist/packages/core/dist/relay-auth.d.ts +40 -0
  83. package/dist/packages/core/dist/relay-auth.js +106 -0
  84. package/dist/packages/core/dist/relay-auth.js.map +1 -0
  85. package/dist/packages/core/dist/revocation.d.ts +55 -0
  86. package/dist/packages/core/dist/revocation.js +88 -0
  87. package/dist/packages/core/dist/revocation.js.map +1 -0
  88. package/dist/packages/core/dist/schema.d.ts +11 -0
  89. package/dist/packages/core/dist/schema.js +48 -0
  90. package/dist/packages/core/dist/schema.js.map +1 -0
  91. package/dist/packages/core/dist/types.d.ts +172 -0
  92. package/dist/packages/core/dist/types.js +2 -0
  93. package/dist/packages/core/dist/types.js.map +1 -0
  94. package/dist/packages/ledger/dist/index.d.ts +84 -0
  95. package/dist/packages/ledger/dist/index.js +269 -0
  96. package/dist/packages/ledger/dist/index.js.map +1 -0
  97. package/dist/packages/relay/dist/fetch.d.ts +223 -0
  98. package/dist/packages/relay/dist/fetch.js +1210 -0
  99. package/dist/packages/relay/dist/fetch.js.map +1 -0
  100. package/dist/packages/relay/dist/index.d.ts +92 -0
  101. package/dist/packages/relay/dist/index.js +707 -0
  102. package/dist/packages/relay/dist/index.js.map +1 -0
  103. package/dist/packages/relay/dist/journal.d.ts +70 -0
  104. package/dist/packages/relay/dist/journal.js +310 -0
  105. package/dist/packages/relay/dist/journal.js.map +1 -0
  106. package/dist/packages/relay/dist/retry.d.ts +9 -0
  107. package/dist/packages/relay/dist/retry.js +39 -0
  108. package/dist/packages/relay/dist/retry.js.map +1 -0
  109. package/dist/packages/relay/dist/ssrf.d.ts +32 -0
  110. package/dist/packages/relay/dist/ssrf.js +213 -0
  111. package/dist/packages/relay/dist/ssrf.js.map +1 -0
  112. package/dist/packages/relay/dist/worker.d.ts +85 -0
  113. package/dist/packages/relay/dist/worker.js +411 -0
  114. package/dist/packages/relay/dist/worker.js.map +1 -0
  115. package/dist/packages/runtime/dist/a2a.d.ts +8 -0
  116. package/dist/packages/runtime/dist/a2a.js +69 -0
  117. package/dist/packages/runtime/dist/a2a.js.map +1 -0
  118. package/dist/packages/runtime/dist/adapter.d.ts +51 -0
  119. package/dist/packages/runtime/dist/adapter.js +2 -0
  120. package/dist/packages/runtime/dist/adapter.js.map +1 -0
  121. package/dist/packages/runtime/dist/approval-providers.d.ts +97 -0
  122. package/dist/packages/runtime/dist/approval-providers.js +269 -0
  123. package/dist/packages/runtime/dist/approval-providers.js.map +1 -0
  124. package/dist/packages/runtime/dist/daily-limit.d.ts +2 -0
  125. package/dist/packages/runtime/dist/daily-limit.js +54 -0
  126. package/dist/packages/runtime/dist/daily-limit.js.map +1 -0
  127. package/dist/packages/runtime/dist/gateway.d.ts +35 -0
  128. package/dist/packages/runtime/dist/gateway.js +92 -0
  129. package/dist/packages/runtime/dist/gateway.js.map +1 -0
  130. package/dist/packages/runtime/dist/inbox.d.ts +10 -0
  131. package/dist/packages/runtime/dist/inbox.js +24 -0
  132. package/dist/packages/runtime/dist/inbox.js.map +1 -0
  133. package/dist/packages/runtime/dist/index.d.ts +13 -0
  134. package/dist/packages/runtime/dist/index.js +14 -0
  135. package/dist/packages/runtime/dist/index.js.map +1 -0
  136. package/dist/packages/runtime/dist/mcp-server.d.ts +90 -0
  137. package/dist/packages/runtime/dist/mcp-server.js +631 -0
  138. package/dist/packages/runtime/dist/mcp-server.js.map +1 -0
  139. package/dist/packages/runtime/dist/mcp-tool-catalog.d.ts +3 -0
  140. package/dist/packages/runtime/dist/mcp-tool-catalog.js +491 -0
  141. package/dist/packages/runtime/dist/mcp-tool-catalog.js.map +1 -0
  142. package/dist/packages/runtime/dist/mcp.d.ts +73 -0
  143. package/dist/packages/runtime/dist/mcp.js +67 -0
  144. package/dist/packages/runtime/dist/mcp.js.map +1 -0
  145. package/dist/packages/runtime/dist/policy.d.ts +19 -0
  146. package/dist/packages/runtime/dist/policy.js +41 -0
  147. package/dist/packages/runtime/dist/policy.js.map +1 -0
  148. package/dist/packages/runtime/dist/quota.d.ts +39 -0
  149. package/dist/packages/runtime/dist/quota.js +147 -0
  150. package/dist/packages/runtime/dist/quota.js.map +1 -0
  151. package/dist/packages/runtime/dist/session-audit.d.ts +88 -0
  152. package/dist/packages/runtime/dist/session-audit.js +415 -0
  153. package/dist/packages/runtime/dist/session-audit.js.map +1 -0
  154. package/dist/packages/runtime/dist/session.d.ts +288 -0
  155. package/dist/packages/runtime/dist/session.js +1880 -0
  156. package/dist/packages/runtime/dist/session.js.map +1 -0
  157. package/dist/packages/runtime/dist/verifier.d.ts +64 -0
  158. package/dist/packages/runtime/dist/verifier.js +109 -0
  159. package/dist/packages/runtime/dist/verifier.js.map +1 -0
  160. package/dist/packages/sandbox/dist/container.d.ts +33 -0
  161. package/dist/packages/sandbox/dist/container.js +189 -0
  162. package/dist/packages/sandbox/dist/container.js.map +1 -0
  163. package/dist/packages/sandbox/dist/index.d.ts +34 -0
  164. package/dist/packages/sandbox/dist/index.js +179 -0
  165. package/dist/packages/sandbox/dist/index.js.map +1 -0
  166. package/dist/packages/sandbox/dist/permission.d.ts +58 -0
  167. package/dist/packages/sandbox/dist/permission.js +90 -0
  168. package/dist/packages/sandbox/dist/permission.js.map +1 -0
  169. package/dist/spec/README.ja.md +76 -0
  170. package/dist/spec/README.md +135 -0
  171. package/dist/spec/ack-receipt.schema.json +77 -0
  172. package/dist/spec/agent-card.schema.json +83 -0
  173. package/dist/spec/approval-receipt.schema.json +94 -0
  174. package/dist/spec/audit-entry.schema.json +101 -0
  175. package/dist/spec/capability-token.schema.json +133 -0
  176. package/dist/spec/envelope.schema.json +197 -0
  177. package/dist/spec/examples/sample-ack-receipt.json +16 -0
  178. package/dist/spec/examples/sample-agent-card.json +35 -0
  179. package/dist/spec/examples/sample-approval-receipt.json +18 -0
  180. package/dist/spec/examples/sample-audit-entry.json +37 -0
  181. package/dist/spec/examples/sample-capability-token.json +39 -0
  182. package/dist/spec/examples/sample-envelope.json +21 -0
  183. package/dist/spec/examples/sample-task-manifest.json +141 -0
  184. package/dist/spec/examples/sample-usage-receipt.json +19 -0
  185. package/dist/spec/task-manifest.schema.json +422 -0
  186. package/dist/spec/usage-receipt.schema.json +91 -0
  187. package/package.json +61 -5
@@ -0,0 +1,83 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://acp-spec.local/schemas/v0.1/agent-card.schema.json",
4
+ "title": "agent-card",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": ["payload", "signature"],
8
+ "properties": {
9
+ "payload": {
10
+ "type": "object",
11
+ "additionalProperties": false,
12
+ "required": [
13
+ "type",
14
+ "name",
15
+ "description",
16
+ "ownerDid",
17
+ "agentDid",
18
+ "relayEndpoint",
19
+ "skills",
20
+ "costModes",
21
+ "version",
22
+ "expiresAt"
23
+ ],
24
+ "properties": {
25
+ "type": { "const": "AgentCard" },
26
+ "name": { "type": "string", "minLength": 1 },
27
+ "description": { "type": "string" },
28
+ "ownerDid": {
29
+ "type": "string",
30
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
31
+ },
32
+ "agentDid": {
33
+ "type": "string",
34
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
35
+ },
36
+ "relayEndpoint": { "type": "string", "minLength": 1 },
37
+ "skills": {
38
+ "type": "array",
39
+ "items": {
40
+ "type": "object",
41
+ "additionalProperties": false,
42
+ "required": ["id", "name"],
43
+ "properties": {
44
+ "id": { "type": "string", "minLength": 1 },
45
+ "name": { "type": "string" },
46
+ "description": { "type": "string" },
47
+ "inputSchema": {},
48
+ "outputSchema": {}
49
+ }
50
+ }
51
+ },
52
+ "costModes": {
53
+ "type": "array",
54
+ "minItems": 1,
55
+ "items": {
56
+ "enum": ["worker_byok", "bilateral_quota", "external_settlement_plugin"]
57
+ }
58
+ },
59
+ "version": { "type": "string", "minLength": 1 },
60
+ "expiresAt": { "type": "string", "format": "date-time" },
61
+ "agentDelegation": { "$ref": "#/$defs/signature" }
62
+ }
63
+ },
64
+ "signature": { "$ref": "#/$defs/signature" }
65
+ },
66
+ "$defs": {
67
+ "signature": {
68
+ "type": "object",
69
+ "additionalProperties": false,
70
+ "required": ["signerDid", "canonicalization", "payloadDigest", "signedAt", "signature"],
71
+ "properties": {
72
+ "signerDid": {
73
+ "type": "string",
74
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
75
+ },
76
+ "canonicalization": { "const": "RFC8785-JCS" },
77
+ "payloadDigest": { "type": "string", "pattern": "^sha256:[a-f0-9]{64}$" },
78
+ "signedAt": { "type": "string", "format": "date-time" },
79
+ "signature": { "type": "string", "pattern": "^ed25519:[A-Za-z0-9_-]{86}$" }
80
+ }
81
+ }
82
+ }
83
+ }
@@ -0,0 +1,94 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://acp-spec.local/schemas/v0.1/approval-receipt.schema.json",
4
+ "title": "approval-receipt",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": [
8
+ "payload",
9
+ "signature"
10
+ ],
11
+ "properties": {
12
+ "payload": {
13
+ "type": "object",
14
+ "additionalProperties": false,
15
+ "required": [
16
+ "type",
17
+ "receiptId",
18
+ "taskId",
19
+ "gate",
20
+ "targetDigest",
21
+ "decision",
22
+ "approvedAt"
23
+ ],
24
+ "properties": {
25
+ "type": {
26
+ "const": "ApprovalReceipt"
27
+ },
28
+ "receiptId": {
29
+ "type": "string",
30
+ "minLength": 1
31
+ },
32
+ "taskId": {
33
+ "type": "string",
34
+ "minLength": 1
35
+ },
36
+ "gate": {
37
+ "enum": [
38
+ "contract_acceptance",
39
+ "external_side_effect",
40
+ "budget_increase",
41
+ "redelegation",
42
+ "final_verification"
43
+ ]
44
+ },
45
+ "targetDigest": {
46
+ "type": "string",
47
+ "pattern": "^sha256:[a-f0-9]{64}$"
48
+ },
49
+ "decision": {
50
+ "enum": [
51
+ "APPROVED",
52
+ "REJECTED"
53
+ ]
54
+ },
55
+ "approvedAt": {
56
+ "type": "string",
57
+ "format": "date-time"
58
+ }
59
+ }
60
+ },
61
+ "signature": {
62
+ "type": "object",
63
+ "additionalProperties": false,
64
+ "required": [
65
+ "signerDid",
66
+ "canonicalization",
67
+ "payloadDigest",
68
+ "signedAt",
69
+ "signature"
70
+ ],
71
+ "properties": {
72
+ "signerDid": {
73
+ "type": "string",
74
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
75
+ },
76
+ "canonicalization": {
77
+ "const": "RFC8785-JCS"
78
+ },
79
+ "payloadDigest": {
80
+ "type": "string",
81
+ "pattern": "^sha256:[a-f0-9]{64}$"
82
+ },
83
+ "signedAt": {
84
+ "type": "string",
85
+ "format": "date-time"
86
+ },
87
+ "signature": {
88
+ "type": "string",
89
+ "pattern": "^ed25519:[A-Za-z0-9_-]{86}$"
90
+ }
91
+ }
92
+ }
93
+ }
94
+ }
@@ -0,0 +1,101 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://acp-spec.local/schemas/v0.1/audit-entry.schema.json",
4
+ "title": "audit-entry",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": [
8
+ "body",
9
+ "entryHash",
10
+ "actorSignature",
11
+ "counterSignature"
12
+ ],
13
+ "properties": {
14
+ "body": {
15
+ "type": "object",
16
+ "additionalProperties": false,
17
+ "required": [
18
+ "taskId",
19
+ "seq",
20
+ "prevEntryHash",
21
+ "actorDid",
22
+ "receiverDid",
23
+ "eventType",
24
+ "payload"
25
+ ],
26
+ "properties": {
27
+ "taskId": {
28
+ "type": "string",
29
+ "minLength": 1
30
+ },
31
+ "seq": {
32
+ "type": "integer",
33
+ "minimum": 0
34
+ },
35
+ "prevEntryHash": {
36
+ "anyOf": [
37
+ {
38
+ "type": "string",
39
+ "pattern": "^sha256:[a-f0-9]{64}$"
40
+ },
41
+ {
42
+ "type": "null"
43
+ }
44
+ ]
45
+ },
46
+ "actorDid": {
47
+ "type": "string",
48
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
49
+ },
50
+ "receiverDid": {
51
+ "type": "string",
52
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
53
+ },
54
+ "eventType": {
55
+ "type": "string",
56
+ "minLength": 1
57
+ },
58
+ "payload": {}
59
+ }
60
+ },
61
+ "entryHash": {
62
+ "type": "string",
63
+ "pattern": "^sha256:[a-f0-9]{64}$"
64
+ },
65
+ "actorSignature": {
66
+ "type": "object",
67
+ "additionalProperties": false,
68
+ "required": [
69
+ "signerDid",
70
+ "canonicalization",
71
+ "payloadDigest",
72
+ "signedAt",
73
+ "signature"
74
+ ],
75
+ "properties": {
76
+ "signerDid": {
77
+ "type": "string",
78
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
79
+ },
80
+ "canonicalization": {
81
+ "const": "RFC8785-JCS"
82
+ },
83
+ "payloadDigest": {
84
+ "type": "string",
85
+ "pattern": "^sha256:[a-f0-9]{64}$"
86
+ },
87
+ "signedAt": {
88
+ "type": "string",
89
+ "format": "date-time"
90
+ },
91
+ "signature": {
92
+ "type": "string",
93
+ "pattern": "^ed25519:[A-Za-z0-9_-]{86}$"
94
+ }
95
+ }
96
+ },
97
+ "counterSignature": {
98
+ "$ref": "https://acp-spec.local/schemas/v0.1/ack-receipt.schema.json"
99
+ }
100
+ }
101
+ }
@@ -0,0 +1,133 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://acp-spec.local/schemas/v0.1/capability-token.schema.json",
4
+ "title": "capability-token",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": [
8
+ "payload",
9
+ "signature"
10
+ ],
11
+ "properties": {
12
+ "payload": {
13
+ "type": "object",
14
+ "additionalProperties": false,
15
+ "required": [
16
+ "type",
17
+ "id",
18
+ "issuer",
19
+ "audience",
20
+ "taskId",
21
+ "resource",
22
+ "allowedTools",
23
+ "argConstraints",
24
+ "maxCalls",
25
+ "notBefore",
26
+ "expiresAt",
27
+ "maxDepth",
28
+ "parentHash"
29
+ ],
30
+ "properties": {
31
+ "type": {
32
+ "const": "CapabilityToken"
33
+ },
34
+ "id": {
35
+ "type": "string",
36
+ "minLength": 1
37
+ },
38
+ "issuer": {
39
+ "type": "string",
40
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
41
+ },
42
+ "audience": {
43
+ "type": "string",
44
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
45
+ },
46
+ "taskId": {
47
+ "type": "string",
48
+ "minLength": 1
49
+ },
50
+ "resource": {
51
+ "type": "string",
52
+ "pattern": "^[^\\\\]*$",
53
+ "minLength": 1
54
+ },
55
+ "allowedTools": {
56
+ "type": "array",
57
+ "minItems": 1,
58
+ "uniqueItems": true,
59
+ "items": {
60
+ "type": "string",
61
+ "minLength": 1
62
+ }
63
+ },
64
+ "argConstraints": {
65
+ "type": "object",
66
+ "additionalProperties": {
67
+ "type": "object"
68
+ }
69
+ },
70
+ "maxCalls": {
71
+ "type": "integer",
72
+ "minimum": 1
73
+ },
74
+ "notBefore": {
75
+ "type": "string",
76
+ "format": "date-time"
77
+ },
78
+ "expiresAt": {
79
+ "type": "string",
80
+ "format": "date-time"
81
+ },
82
+ "maxDepth": {
83
+ "type": "integer",
84
+ "minimum": 0,
85
+ "maximum": 31
86
+ },
87
+ "parentHash": {
88
+ "anyOf": [
89
+ {
90
+ "type": "string",
91
+ "pattern": "^sha256:[a-f0-9]{64}$"
92
+ },
93
+ {
94
+ "type": "null"
95
+ }
96
+ ]
97
+ }
98
+ }
99
+ },
100
+ "signature": {
101
+ "type": "object",
102
+ "additionalProperties": false,
103
+ "required": [
104
+ "signerDid",
105
+ "canonicalization",
106
+ "payloadDigest",
107
+ "signedAt",
108
+ "signature"
109
+ ],
110
+ "properties": {
111
+ "signerDid": {
112
+ "type": "string",
113
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
114
+ },
115
+ "canonicalization": {
116
+ "const": "RFC8785-JCS"
117
+ },
118
+ "payloadDigest": {
119
+ "type": "string",
120
+ "pattern": "^sha256:[a-f0-9]{64}$"
121
+ },
122
+ "signedAt": {
123
+ "type": "string",
124
+ "format": "date-time"
125
+ },
126
+ "signature": {
127
+ "type": "string",
128
+ "pattern": "^ed25519:[A-Za-z0-9_-]{86}$"
129
+ }
130
+ }
131
+ }
132
+ }
133
+ }
@@ -0,0 +1,197 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://acp-spec.local/schemas/v0.1/envelope.schema.json",
4
+ "title": "envelope",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": [
8
+ "payload",
9
+ "signature"
10
+ ],
11
+ "properties": {
12
+ "payload": {
13
+ "type": "object",
14
+ "additionalProperties": false,
15
+ "required": [
16
+ "type",
17
+ "envelopeId",
18
+ "taskId",
19
+ "seq",
20
+ "eventType",
21
+ "senderDid",
22
+ "recipientDid",
23
+ "payload"
24
+ ],
25
+ "properties": {
26
+ "type": {
27
+ "const": "SignedEnvelope"
28
+ },
29
+ "envelopeId": {
30
+ "type": "string",
31
+ "minLength": 1
32
+ },
33
+ "taskId": {
34
+ "type": "string",
35
+ "minLength": 1
36
+ },
37
+ "seq": {
38
+ "type": "integer",
39
+ "minimum": 0
40
+ },
41
+ "eventType": {
42
+ "type": "string",
43
+ "minLength": 1
44
+ },
45
+ "senderDid": {
46
+ "type": "string",
47
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
48
+ },
49
+ "recipientDid": {
50
+ "type": "string",
51
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
52
+ },
53
+ "payload": {}
54
+ }
55
+ },
56
+ "signature": {
57
+ "type": "object",
58
+ "additionalProperties": false,
59
+ "required": [
60
+ "signerDid",
61
+ "canonicalization",
62
+ "payloadDigest",
63
+ "signedAt",
64
+ "signature"
65
+ ],
66
+ "properties": {
67
+ "signerDid": {
68
+ "type": "string",
69
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
70
+ },
71
+ "canonicalization": {
72
+ "const": "RFC8785-JCS"
73
+ },
74
+ "payloadDigest": {
75
+ "type": "string",
76
+ "pattern": "^sha256:[a-f0-9]{64}$"
77
+ },
78
+ "signedAt": {
79
+ "type": "string",
80
+ "format": "date-time"
81
+ },
82
+ "signature": {
83
+ "type": "string",
84
+ "pattern": "^ed25519:[A-Za-z0-9_-]{86}$"
85
+ }
86
+ }
87
+ }
88
+ },
89
+ "$defs": {
90
+ "ackReceipt": {
91
+ "type": "object",
92
+ "additionalProperties": false,
93
+ "required": [
94
+ "payload",
95
+ "signature"
96
+ ],
97
+ "properties": {
98
+ "payload": {
99
+ "type": "object",
100
+ "additionalProperties": false,
101
+ "required": [
102
+ "type",
103
+ "taskId",
104
+ "entryHash",
105
+ "actorDid",
106
+ "receiverDid"
107
+ ],
108
+ "properties": {
109
+ "type": {
110
+ "const": "AckReceipt"
111
+ },
112
+ "taskId": {
113
+ "type": "string",
114
+ "minLength": 1
115
+ },
116
+ "entryHash": {
117
+ "type": "string",
118
+ "pattern": "^sha256:[a-f0-9]{64}$"
119
+ },
120
+ "actorDid": {
121
+ "type": "string",
122
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
123
+ },
124
+ "receiverDid": {
125
+ "type": "string",
126
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
127
+ }
128
+ }
129
+ },
130
+ "signature": {
131
+ "type": "object",
132
+ "additionalProperties": false,
133
+ "required": [
134
+ "signerDid",
135
+ "canonicalization",
136
+ "payloadDigest",
137
+ "signedAt",
138
+ "signature"
139
+ ],
140
+ "properties": {
141
+ "signerDid": {
142
+ "type": "string",
143
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
144
+ },
145
+ "canonicalization": {
146
+ "const": "RFC8785-JCS"
147
+ },
148
+ "payloadDigest": {
149
+ "type": "string",
150
+ "pattern": "^sha256:[a-f0-9]{64}$"
151
+ },
152
+ "signedAt": {
153
+ "type": "string",
154
+ "format": "date-time"
155
+ },
156
+ "signature": {
157
+ "type": "string",
158
+ "pattern": "^ed25519:[A-Za-z0-9_-]{86}$"
159
+ }
160
+ }
161
+ }
162
+ }
163
+ },
164
+ "signature": {
165
+ "type": "object",
166
+ "additionalProperties": false,
167
+ "required": [
168
+ "signerDid",
169
+ "canonicalization",
170
+ "payloadDigest",
171
+ "signedAt",
172
+ "signature"
173
+ ],
174
+ "properties": {
175
+ "signerDid": {
176
+ "type": "string",
177
+ "pattern": "^did:key:z[1-9A-HJ-NP-Za-km-z]{32,128}$"
178
+ },
179
+ "canonicalization": {
180
+ "const": "RFC8785-JCS"
181
+ },
182
+ "payloadDigest": {
183
+ "type": "string",
184
+ "pattern": "^sha256:[a-f0-9]{64}$"
185
+ },
186
+ "signedAt": {
187
+ "type": "string",
188
+ "format": "date-time"
189
+ },
190
+ "signature": {
191
+ "type": "string",
192
+ "pattern": "^ed25519:[A-Za-z0-9_-]{86}$"
193
+ }
194
+ }
195
+ }
196
+ }
197
+ }
@@ -0,0 +1,16 @@
1
+ {
2
+ "payload": {
3
+ "type": "AckReceipt",
4
+ "taskId": "task_examples01",
5
+ "entryHash": "sha256:810857bf190cfaab9c138e27991465ad0dc3b75557c657c142d1023b5ac44b97",
6
+ "actorDid": "did:key:z6MkiTBz1ymuepAQ4HEHYSF1H8quG5GLVVQR3djdX3mDooWp",
7
+ "receiverDid": "did:key:z6MkpbX9WrS8mmVFD4ThkenxbkMs9V7AoT3nNL8xkoSt8PDk"
8
+ },
9
+ "signature": {
10
+ "signerDid": "did:key:z6MkpbX9WrS8mmVFD4ThkenxbkMs9V7AoT3nNL8xkoSt8PDk",
11
+ "canonicalization": "RFC8785-JCS",
12
+ "payloadDigest": "sha256:89e8e531e602b493b6819dec4ea86ea512f09b36e16677c8e0a7fc7d9de6b491",
13
+ "signedAt": "2026-10-25T12:38:16.784Z",
14
+ "signature": "ed25519:JvzvJpdV0nAFer2Q7XiiRcVwwBNPnGP1BlJjVwqyUydLN-kJyfcZHxA4Xs9Jl6htEIrUt9AL2ADg1JZ50b43BQ"
15
+ }
16
+ }
@@ -0,0 +1,35 @@
1
+ {
2
+ "payload": {
3
+ "type": "AgentCard",
4
+ "version": "0.2.0",
5
+ "description": "Signed agent card with an agent-key delegation",
6
+ "costModes": [
7
+ "worker_byok"
8
+ ],
9
+ "name": "Example Worker",
10
+ "skills": [
11
+ {
12
+ "id": "json-task",
13
+ "name": "JSON task"
14
+ }
15
+ ],
16
+ "ownerDid": "did:key:z6MkhEQK4haXyh7AeNPvGUtqgFv45mxKaBPiu4rY9MVf9wBN",
17
+ "agentDid": "did:key:z6Mkv2MyKMWdD5KjnAuC6qvNokzGcq8WyWaHYLChZX2FPogo",
18
+ "relayEndpoint": "https://relay.example",
19
+ "expiresAt": "2026-10-28T15:32:19.599Z",
20
+ "agentDelegation": {
21
+ "signerDid": "did:key:z6Mkv2MyKMWdD5KjnAuC6qvNokzGcq8WyWaHYLChZX2FPogo",
22
+ "canonicalization": "RFC8785-JCS",
23
+ "payloadDigest": "sha256:019748fd70b5e1579775b13478cc2cb4e14d2e472feefcc6c61d134e88e47aeb",
24
+ "signedAt": "2026-10-27T15:32:19.599Z",
25
+ "signature": "ed25519:1RkAOSuZEwGZdnISrr7Dzdbmtw-SBv2ehC3BiDLYeOVc8OeXHdbIpe8nTszKdrkF3m2RGSda43BhbWb_6GnaAg"
26
+ }
27
+ },
28
+ "signature": {
29
+ "signerDid": "did:key:z6MkhEQK4haXyh7AeNPvGUtqgFv45mxKaBPiu4rY9MVf9wBN",
30
+ "canonicalization": "RFC8785-JCS",
31
+ "payloadDigest": "sha256:2ea9933656c9a1ae988391be9ce188484f798a7ab767bcc017720c85243e6d55",
32
+ "signedAt": "2026-10-27T15:32:19.599Z",
33
+ "signature": "ed25519:WXTwXJbqYw_EGC0gQOMU7fJblzDdgAPOHz5dIqD-4ZOqkpjpqRLZXjxbZWC87DYuIcvZJ15KIa-osnlSsvTZAQ"
34
+ }
35
+ }
@@ -0,0 +1,18 @@
1
+ {
2
+ "payload": {
3
+ "type": "ApprovalReceipt",
4
+ "receiptId": "98a2c3e1-a27e-4329-bde2-b262579303bc",
5
+ "taskId": "task_examples01",
6
+ "gate": "contract_acceptance",
7
+ "targetDigest": "sha256:4c94dfff1758d15da9c3e100c88f89503ee72c3a7f7f7691ade54326fbbe606f",
8
+ "decision": "APPROVED",
9
+ "approvedAt": "2026-10-25T12:38:16.778Z"
10
+ },
11
+ "signature": {
12
+ "signerDid": "did:key:z6MkiTBz1ymuepAQ4HEHYSF1H8quG5GLVVQR3djdX3mDooWp",
13
+ "canonicalization": "RFC8785-JCS",
14
+ "payloadDigest": "sha256:a9200b7d97cc50eda122f837bca839403e08e04d2060fdb8e94fd49ac908e1ca",
15
+ "signedAt": "2026-10-25T12:38:16.778Z",
16
+ "signature": "ed25519:18xWvETRZ2GgDucQ0OjkuRyYjKxtaYVyA16iiw1Ky8XcMHJCkBanK0SnErwv3ixOjHl39Uo2A91kk9c7o427CA"
17
+ }
18
+ }