The AI trust layer between agents: identity, agreements, safeguards, and outcome intelligence for A2A.

Viewing files at commit 32cb43fd4001Commit detailsView latest

schemas/v0.1/live_session_activation.schema.json 437 lines · 12.1 KB · json
1
{
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
  "type": "object",
4
  "properties": {
5
    "type": {
6
      "type": "string",
7
      "const": "openclasp.session.activation"
8
    },
9
    "version": {
10
      "type": "string",
11
      "const": "1"
12
    },
13
    "activationId": {
14
      "type": "string",
15
      "format": "uuid",
16
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
17
    },
18
    "interactionId": {
19
      "type": "string",
20
      "format": "uuid",
21
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
22
    },
23
    "agentId": {
24
      "type": "string",
25
      "minLength": 1
26
    },
27
    "sessionId": {
28
      "type": "string",
29
      "format": "uuid",
30
      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
31
    },
32
    "role": {
33
      "type": "string",
34
      "enum": [
35
        "initiator",
36
        "responder"
37
      ]
38
    },
39
    "peer": {
40
      "type": "object",
41
      "properties": {
42
        "agentId": {
43
          "type": "string",
44
          "minLength": 1
45
        },
46
        "sessionId": {
47
          "type": "string",
48
          "format": "uuid",
49
          "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
50
        },
51
        "endpoint": {
52
          "type": "string",
53
          "format": "uri"
54
        },
55
        "bearerToken": {
56
          "type": "string",
57
          "minLength": 1
58
        },
59
        "verificationKey": {
60
          "type": "string",
61
          "minLength": 1
62
        }
63
      },
64
      "required": [
65
        "agentId",
66
        "sessionId",
67
        "endpoint",
68
        "bearerToken",
69
        "verificationKey"
70
      ],
71
      "additionalProperties": false
72
    },
73
    "reporting": {
74
      "type": "object",
75
      "properties": {
76
        "endpoint": {
77
          "type": "string",
78
          "format": "uri"
79
        },
80
        "completionEndpoint": {
81
          "type": "string",
82
          "format": "uri"
83
        },
84
        "feedbackEndpoint": {
85
          "type": "string",
86
          "format": "uri"
87
        },
88
        "assuranceResponseEndpoint": {
89
          "type": "string",
90
          "format": "uri"
91
        },
92
        "bearerToken": {
93
          "type": "string",
94
          "minLength": 1
95
        }
96
      },
97
      "required": [
98
        "endpoint",
99
        "bearerToken"
100
      ],
101
      "additionalProperties": false
102
    },
103
    "privateInsights": {
104
      "type": "array",
105
      "items": {
106
        "type": "object",
107
        "properties": {
108
          "code": {
109
            "type": "string",
110
            "minLength": 1
111
          },
112
          "severity": {
113
            "type": "string",
114
            "enum": [
115
              "info",
116
              "caution",
117
              "high"
118
            ]
119
          },
120
          "message": {
121
            "type": "string",
122
            "minLength": 1
123
          },
124
          "evidenceReferences": {
125
            "default": [],
126
            "type": "array",
127
            "items": {
128
              "type": "string"
129
            }
130
          },
131
          "requirementReferences": {
132
            "default": [],
133
            "type": "array",
134
            "items": {
135
              "type": "string"
136
            }
137
          },
138
          "confidence": {
139
            "type": "number",
140
            "minimum": 0,
141
            "maximum": 1
142
          }
143
        },
144
        "required": [
145
          "code",
146
          "severity",
147
          "message",
148
          "evidenceReferences",
149
          "requirementReferences"
150
        ],
151
        "additionalProperties": false
152
      }
153
    },
154
    "counterpartyBrief": {
155
      "type": "object",
156
      "properties": {
157
        "briefId": {
158
          "type": "string",
159
          "format": "uuid",
160
          "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
161
        },
162
        "interactionId": {
163
          "type": "string",
164
          "format": "uuid",
165
          "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
166
        },
167
        "contractHash": {
168
          "type": "string",
169
          "minLength": 1
170
        },
171
        "recipientAgentId": {
172
          "type": "string",
173
          "minLength": 1
174
        },
175
        "subjectAgentId": {
176
          "type": "string",
177
          "minLength": 1
178
        },
179
        "taskCategory": {
180
          "type": "string",
181
          "minLength": 1
182
        },
183
        "decision": {
184
          "type": "string",
185
          "enum": [
186
            "ALLOW",
187
            "CHALLENGE",
188
            "DENY"
189
          ]
190
        },
191
        "requirements": {
192
          "maxItems": 100,
193
          "type": "array",
194
          "items": {
195
            "type": "object",
196
            "properties": {
197
              "requirementId": {
198
                "type": "string",
199
                "minLength": 1,
200
                "maxLength": 128
201
              },
202
              "requirement": {
203
                "type": "string",
204
                "minLength": 1,
205
                "maxLength": 1000
206
              },
207
              "kind": {
208
                "type": "string",
209
                "enum": [
210
                  "capability",
211
                  "limitation",
212
                  "success_criterion",
213
                  "deadline",
214
                  "evidence",
215
                  "scope",
216
                  "data",
217
                  "communication",
218
                  "delegation"
219
                ]
220
              },
221
              "status": {
222
                "type": "string",
223
                "enum": [
224
                  "match",
225
                  "partial",
226
                  "mismatch",
227
                  "unknown"
228
                ]
229
              },
230
              "reason": {
231
                "type": "string",
232
                "minLength": 1,
233
                "maxLength": 1000
234
              },
235
              "confidence": {
236
                "type": "number",
237
                "minimum": 0,
238
                "maximum": 1
239
              },
240
              "sources": {
241
                "minItems": 1,
242
                "type": "array",
243
                "items": {
244
                  "type": "string",
245
                  "enum": [
246
                    "contract",
247
                    "self_declared",
248
                    "eligible_history",
249
                    "evidence",
250
                    "version_change"
251
                  ]
252
                }
253
              },
254
              "evidenceReferences": {
255
                "default": [],
256
                "maxItems": 50,
257
                "type": "array",
258
                "items": {
259
                  "type": "string",
260
                  "minLength": 1,
261
                  "maxLength": 2048
262
                }
263
              }
264
            },
265
            "required": [
266
              "requirementId",
267
              "requirement",
268
              "kind",
269
              "status",
270
              "reason",
271
              "confidence",
272
              "sources",
273
              "evidenceReferences"
274
            ],
275
            "additionalProperties": false
276
          }
277
        },
278
        "insights": {
279
          "maxItems": 100,
280
          "type": "array",
281
          "items": {
282
            "type": "object",
283
            "properties": {
284
              "code": {
285
                "type": "string",
286
                "minLength": 1
287
              },
288
              "severity": {
289
                "type": "string",
290
                "enum": [
291
                  "info",
292
                  "caution",
293
                  "high"
294
                ]
295
              },
296
              "message": {
297
                "type": "string",
298
                "minLength": 1
299
              },
300
              "evidenceReferences": {
301
                "default": [],
302
                "type": "array",
303
                "items": {
304
                  "type": "string"
305
                }
306
              },
307
              "requirementReferences": {
308
                "default": [],
309
                "type": "array",
310
                "items": {
311
                  "type": "string"
312
                }
313
              },
314
              "confidence": {
315
                "type": "number",
316
                "minimum": 0,
317
                "maximum": 1
318
              }
319
            },
320
            "required": [
321
              "code",
322
              "severity",
323
              "message",
324
              "evidenceReferences",
325
              "requirementReferences"
326
            ],
327
            "additionalProperties": false
328
          }
329
        },
330
        "relevantSampleSize": {
331
          "type": "integer",
332
          "minimum": 0,
333
          "maximum": 9007199254740991
334
        },
335
        "historyConfidence": {
336
          "type": "number",
337
          "minimum": 0,
338
          "maximum": 1
339
        },
340
        "subjectAgentVersion": {
341
          "type": "string",
342
          "minLength": 1
343
        },
344
        "recommendedContractChanges": {
345
          "default": [],
346
          "maxItems": 50,
347
          "type": "array",
348
          "items": {
349
            "type": "string",
350
            "minLength": 1,
351
            "maxLength": 1000
352
          }
353
        },
354
        "generatedAt": {
355
          "type": "string",
356
          "format": "date-time",
357
          "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
358
        },
359
        "expiresAt": {
360
          "type": "string",
361
          "format": "date-time",
362
          "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
363
        },
364
        "signature": {
365
          "type": "object",
366
          "properties": {
367
            "algorithm": {
368
              "type": "string",
369
              "const": "Ed25519"
370
            },
371
            "keyId": {
372
              "type": "string",
373
              "minLength": 1
374
            },
375
            "value": {
376
              "type": "string",
377
              "minLength": 1
378
            }
379
          },
380
          "required": [
381
            "algorithm",
382
            "keyId",
383
            "value"
384
          ],
385
          "additionalProperties": false
386
        }
387
      },
388
      "required": [
389
        "briefId",
390
        "interactionId",
391
        "contractHash",
392
        "recipientAgentId",
393
        "subjectAgentId",
394
        "taskCategory",
395
        "decision",
396
        "requirements",
397
        "insights",
398
        "relevantSampleSize",
399
        "historyConfidence",
400
        "subjectAgentVersion",
401
        "recommendedContractChanges",
402
        "generatedAt",
403
        "expiresAt"
404
      ],
405
      "additionalProperties": false
406
    },
407
    "contractHash": {
408
      "type": "string",
409
      "minLength": 1
410
    },
411
    "activatedAt": {
412
      "type": "string",
413
      "format": "date-time",
414
      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
415
    },
416
    "expiresAt": {
417
      "type": "string",
418
      "format": "date-time",
419
      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
420
    }
421
  },
422
  "required": [
423
    "type",
424
    "version",
425
    "activationId",
426
    "interactionId",
427
    "agentId",
428
    "sessionId",
429
    "role",
430
    "peer",
431
    "reporting",
432
    "contractHash",
433
    "activatedAt",
434
    "expiresAt"
435
  ],
436
  "additionalProperties": false
437
}