@bluefly/openstandardagents 0.3.0 → 0.3.1
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 +1 -1
- package/README.md +58 -218
- package/dist/cli/commands/diff.command.d.ts +7 -0
- package/dist/cli/commands/diff.command.d.ts.map +1 -0
- package/dist/cli/commands/diff.command.js +181 -0
- package/dist/cli/commands/diff.command.js.map +1 -0
- package/dist/cli/commands/docs.command.d.ts +7 -0
- package/dist/cli/commands/docs.command.d.ts.map +1 -0
- package/dist/cli/commands/docs.command.js +274 -0
- package/dist/cli/commands/docs.command.js.map +1 -0
- package/dist/cli/commands/lint.command.d.ts +7 -0
- package/dist/cli/commands/lint.command.d.ts.map +1 -0
- package/dist/cli/commands/lint.command.js +342 -0
- package/dist/cli/commands/lint.command.js.map +1 -0
- package/dist/cli/commands/serve.command.d.ts +7 -0
- package/dist/cli/commands/serve.command.d.ts.map +1 -0
- package/dist/cli/commands/serve.command.js +232 -0
- package/dist/cli/commands/serve.command.js.map +1 -0
- package/dist/cli/index.js +4 -0
- package/dist/cli/index.js.map +1 -1
- package/dist/di-container.d.ts.map +1 -1
- package/dist/di-container.js +3 -0
- package/dist/di-container.js.map +1 -1
- package/dist/services/git.service.d.ts +40 -0
- package/dist/services/git.service.d.ts.map +1 -0
- package/dist/services/git.service.js +122 -0
- package/dist/services/git.service.js.map +1 -0
- package/dist/spec/v0.3.1/UNIFIED-SCHEMA.md +120 -0
- package/dist/spec/v0.3.1/adapters/drupal.md +541 -0
- package/dist/spec/v0.3.1/adapters/symfony.md +659 -0
- package/dist/spec/v0.3.1/agent-test.schema.json +75 -0
- package/dist/spec/v0.3.1/examples/drupal-content-writer.ossa.yaml +110 -0
- package/dist/spec/v0.3.1/examples/drupal-moderation-assistant.ossa.yaml +96 -0
- package/dist/spec/v0.3.1/examples/quick-wins/complete-agent-with-quick-wins.ossa.yaml +144 -0
- package/dist/spec/v0.3.1/extensions/drupal.md +417 -0
- package/dist/spec/v0.3.1/ossa-0.3.0.schema.json +2787 -0
- package/dist/spec/v0.3.1/ossa-0.3.1.schema.json +2806 -0
- package/dist/spec/v0.3.1/protocols/sse.md +494 -0
- package/dist/spec/v0.3.1/protocols/webrtc.md +600 -0
- package/dist/spec/v0.3.1/protocols/websocket.md +362 -0
- package/dist/spec/v0.3.1/schemas/agent-unified.yaml +165 -0
- package/dist/spec/v0.3.1/schemas/capabilities.yaml +102 -0
- package/dist/spec/v0.3.1/schemas/functions.yaml +75 -0
- package/dist/spec/v0.3.1/schemas/messaging/channel.schema.json +245 -0
- package/dist/spec/v0.3.1/schemas/messaging/delivery-receipt.schema.json +192 -0
- package/dist/spec/v0.3.1/schemas/messaging/message.schema.json +205 -0
- package/dist/spec/v0.3.1/schemas/messaging/subscription.schema.json +214 -0
- package/dist/spec/v0.3.1/schemas/runtime.yaml +102 -0
- package/dist/spec/v0.3.1/schemas/taxonomy.yaml +533 -0
- package/dist/spec/v0.3.1/schemas/unified-llm.yaml +91 -0
- package/dist/spec/v0.3.1/taxonomy.yaml +256 -0
- package/dist/testing/fixtures.d.ts.map +1 -1
- package/dist/testing/fixtures.js +3 -2
- package/dist/testing/fixtures.js.map +1 -1
- package/package.json +3 -31
- package/spec/v0.3.1/UNIFIED-SCHEMA.md +120 -0
- package/spec/v0.3.1/adapters/drupal.md +541 -0
- package/spec/v0.3.1/adapters/symfony.md +659 -0
- package/spec/v0.3.1/agent-test.schema.json +75 -0
- package/spec/v0.3.1/examples/drupal-content-writer.ossa.yaml +110 -0
- package/spec/v0.3.1/examples/drupal-moderation-assistant.ossa.yaml +96 -0
- package/spec/v0.3.1/examples/quick-wins/complete-agent-with-quick-wins.ossa.yaml +144 -0
- package/spec/v0.3.1/extensions/drupal.md +417 -0
- package/spec/v0.3.1/ossa-0.3.0.schema.json +2787 -0
- package/spec/v0.3.1/ossa-0.3.1.schema.json +2806 -0
- package/spec/v0.3.1/protocols/sse.md +494 -0
- package/spec/v0.3.1/protocols/webrtc.md +600 -0
- package/spec/v0.3.1/protocols/websocket.md +362 -0
- package/spec/v0.3.1/schemas/agent-unified.yaml +165 -0
- package/spec/v0.3.1/schemas/capabilities.yaml +102 -0
- package/spec/v0.3.1/schemas/functions.yaml +75 -0
- package/spec/v0.3.1/schemas/messaging/channel.schema.json +245 -0
- package/spec/v0.3.1/schemas/messaging/delivery-receipt.schema.json +192 -0
- package/spec/v0.3.1/schemas/messaging/message.schema.json +205 -0
- package/spec/v0.3.1/schemas/messaging/subscription.schema.json +214 -0
- package/spec/v0.3.1/schemas/runtime.yaml +102 -0
- package/spec/v0.3.1/schemas/taxonomy.yaml +533 -0
- package/spec/v0.3.1/schemas/unified-llm.yaml +91 -0
- package/spec/v0.3.1/taxonomy.yaml +256 -0
- package/dist/types/generated/ossa-0.3.0.types.d.ts +0 -316
- package/dist/types/generated/ossa-0.3.0.types.d.ts.map +0 -1
- package/dist/types/generated/ossa-0.3.0.types.js +0 -8
- package/dist/types/generated/ossa-0.3.0.types.js.map +0 -1
- package/dist/types/generated/ossa-0.3.0.zod.d.ts +0 -17
- package/dist/types/generated/ossa-0.3.0.zod.d.ts.map +0 -1
- package/dist/types/generated/ossa-0.3.0.zod.js +0 -3
- package/dist/types/generated/ossa-0.3.0.zod.js.map +0 -1
|
@@ -0,0 +1,245 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "https://openstandardagents.org/schemas/v0.3.1/messaging/channel.json",
|
|
4
|
+
"title": "OSSA Channel Schema",
|
|
5
|
+
"description": "Schema for message channel configuration in OSSA v0.3.1",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": [
|
|
8
|
+
"name",
|
|
9
|
+
"type"
|
|
10
|
+
],
|
|
11
|
+
"properties": {
|
|
12
|
+
"name": {
|
|
13
|
+
"type": "string",
|
|
14
|
+
"description": "Channel name (must follow naming conventions)",
|
|
15
|
+
"pattern": "^agents\\.([a-z0-9-]+\\.)+[a-z0-9-]+$",
|
|
16
|
+
"minLength": 3,
|
|
17
|
+
"maxLength": 256,
|
|
18
|
+
"examples": [
|
|
19
|
+
"agents.tasks.assigned",
|
|
20
|
+
"agents.code-reviewer.completed",
|
|
21
|
+
"agents.broadcast.shutdown"
|
|
22
|
+
]
|
|
23
|
+
},
|
|
24
|
+
"type": {
|
|
25
|
+
"type": "string",
|
|
26
|
+
"enum": ["direct", "topic", "broadcast"],
|
|
27
|
+
"description": "Channel type determining routing behavior"
|
|
28
|
+
},
|
|
29
|
+
"description": {
|
|
30
|
+
"type": "string",
|
|
31
|
+
"description": "Human-readable channel description",
|
|
32
|
+
"maxLength": 512
|
|
33
|
+
},
|
|
34
|
+
"schema": {
|
|
35
|
+
"type": "string",
|
|
36
|
+
"description": "JSON Schema reference for message validation",
|
|
37
|
+
"format": "uri-reference",
|
|
38
|
+
"examples": [
|
|
39
|
+
"TaskAssigned",
|
|
40
|
+
"https://ossa.dev/schemas/messaging/TaskCompleted.schema.json"
|
|
41
|
+
]
|
|
42
|
+
},
|
|
43
|
+
"qos": {
|
|
44
|
+
"$ref": "#/definitions/ChannelQoS",
|
|
45
|
+
"description": "Default quality of service for this channel"
|
|
46
|
+
},
|
|
47
|
+
"config": {
|
|
48
|
+
"$ref": "#/definitions/ChannelConfig",
|
|
49
|
+
"description": "Channel-specific configuration"
|
|
50
|
+
},
|
|
51
|
+
"metadata": {
|
|
52
|
+
"type": "object",
|
|
53
|
+
"description": "Custom metadata for channel management",
|
|
54
|
+
"additionalProperties": true
|
|
55
|
+
}
|
|
56
|
+
},
|
|
57
|
+
"additionalProperties": false,
|
|
58
|
+
"definitions": {
|
|
59
|
+
"ChannelQoS": {
|
|
60
|
+
"type": "object",
|
|
61
|
+
"description": "Default quality of service settings for channel",
|
|
62
|
+
"properties": {
|
|
63
|
+
"deliveryMode": {
|
|
64
|
+
"type": "string",
|
|
65
|
+
"enum": ["at-most-once", "at-least-once", "exactly-once"],
|
|
66
|
+
"default": "at-least-once"
|
|
67
|
+
},
|
|
68
|
+
"persistent": {
|
|
69
|
+
"type": "boolean",
|
|
70
|
+
"default": true,
|
|
71
|
+
"description": "Messages persist to disk"
|
|
72
|
+
},
|
|
73
|
+
"ordered": {
|
|
74
|
+
"type": "boolean",
|
|
75
|
+
"default": true,
|
|
76
|
+
"description": "Maintain message order"
|
|
77
|
+
},
|
|
78
|
+
"maxRetries": {
|
|
79
|
+
"type": "integer",
|
|
80
|
+
"minimum": 0,
|
|
81
|
+
"maximum": 100,
|
|
82
|
+
"default": 3,
|
|
83
|
+
"description": "Maximum delivery retry attempts"
|
|
84
|
+
},
|
|
85
|
+
"retryBackoff": {
|
|
86
|
+
"type": "string",
|
|
87
|
+
"enum": ["none", "linear", "exponential"],
|
|
88
|
+
"default": "exponential",
|
|
89
|
+
"description": "Retry backoff strategy"
|
|
90
|
+
}
|
|
91
|
+
},
|
|
92
|
+
"additionalProperties": false
|
|
93
|
+
},
|
|
94
|
+
"ChannelConfig": {
|
|
95
|
+
"type": "object",
|
|
96
|
+
"description": "Channel configuration options",
|
|
97
|
+
"properties": {
|
|
98
|
+
"maxMessageSize": {
|
|
99
|
+
"type": "integer",
|
|
100
|
+
"minimum": 1024,
|
|
101
|
+
"maximum": 10485760,
|
|
102
|
+
"default": 1048576,
|
|
103
|
+
"description": "Maximum message size in bytes (default: 1MB)"
|
|
104
|
+
},
|
|
105
|
+
"maxSubscribers": {
|
|
106
|
+
"type": "integer",
|
|
107
|
+
"minimum": 1,
|
|
108
|
+
"maximum": 10000,
|
|
109
|
+
"default": 1000,
|
|
110
|
+
"description": "Maximum concurrent subscribers"
|
|
111
|
+
},
|
|
112
|
+
"messageRetention": {
|
|
113
|
+
"type": "integer",
|
|
114
|
+
"minimum": 0,
|
|
115
|
+
"maximum": 2592000,
|
|
116
|
+
"default": 86400,
|
|
117
|
+
"description": "Message retention period in seconds (default: 24 hours, 0 = no retention)"
|
|
118
|
+
},
|
|
119
|
+
"deadLetterQueue": {
|
|
120
|
+
"type": "boolean",
|
|
121
|
+
"default": true,
|
|
122
|
+
"description": "Enable dead letter queue for failed messages"
|
|
123
|
+
},
|
|
124
|
+
"dlqChannel": {
|
|
125
|
+
"type": "string",
|
|
126
|
+
"description": "Custom DLQ channel name (default: {channel}.dlq)",
|
|
127
|
+
"pattern": "^agents\\.([a-z0-9-]+\\.)+[a-z0-9-]+$"
|
|
128
|
+
},
|
|
129
|
+
"rateLimiting": {
|
|
130
|
+
"type": "object",
|
|
131
|
+
"description": "Rate limiting configuration",
|
|
132
|
+
"properties": {
|
|
133
|
+
"enabled": {
|
|
134
|
+
"type": "boolean",
|
|
135
|
+
"default": false
|
|
136
|
+
},
|
|
137
|
+
"maxMessagesPerSecond": {
|
|
138
|
+
"type": "integer",
|
|
139
|
+
"minimum": 1,
|
|
140
|
+
"maximum": 100000
|
|
141
|
+
},
|
|
142
|
+
"burstSize": {
|
|
143
|
+
"type": "integer",
|
|
144
|
+
"minimum": 1,
|
|
145
|
+
"maximum": 1000
|
|
146
|
+
}
|
|
147
|
+
},
|
|
148
|
+
"additionalProperties": false
|
|
149
|
+
},
|
|
150
|
+
"encryption": {
|
|
151
|
+
"type": "object",
|
|
152
|
+
"description": "Channel-level encryption settings",
|
|
153
|
+
"properties": {
|
|
154
|
+
"enabled": {
|
|
155
|
+
"type": "boolean",
|
|
156
|
+
"default": false
|
|
157
|
+
},
|
|
158
|
+
"algorithm": {
|
|
159
|
+
"type": "string",
|
|
160
|
+
"enum": ["AES-256-GCM", "ChaCha20-Poly1305"],
|
|
161
|
+
"default": "AES-256-GCM"
|
|
162
|
+
},
|
|
163
|
+
"keyRef": {
|
|
164
|
+
"type": "string",
|
|
165
|
+
"description": "Reference to encryption key in secret store"
|
|
166
|
+
}
|
|
167
|
+
},
|
|
168
|
+
"required": ["enabled"],
|
|
169
|
+
"if": {
|
|
170
|
+
"properties": {
|
|
171
|
+
"enabled": { "const": true }
|
|
172
|
+
}
|
|
173
|
+
},
|
|
174
|
+
"then": {
|
|
175
|
+
"required": ["keyRef"]
|
|
176
|
+
},
|
|
177
|
+
"additionalProperties": false
|
|
178
|
+
}
|
|
179
|
+
},
|
|
180
|
+
"additionalProperties": false
|
|
181
|
+
}
|
|
182
|
+
},
|
|
183
|
+
"examples": [
|
|
184
|
+
{
|
|
185
|
+
"name": "agents.tasks.assigned",
|
|
186
|
+
"type": "topic",
|
|
187
|
+
"description": "Task assignment notifications",
|
|
188
|
+
"schema": "TaskAssigned",
|
|
189
|
+
"qos": {
|
|
190
|
+
"deliveryMode": "at-least-once",
|
|
191
|
+
"persistent": true,
|
|
192
|
+
"ordered": true,
|
|
193
|
+
"maxRetries": 5,
|
|
194
|
+
"retryBackoff": "exponential"
|
|
195
|
+
},
|
|
196
|
+
"config": {
|
|
197
|
+
"maxMessageSize": 1048576,
|
|
198
|
+
"maxSubscribers": 100,
|
|
199
|
+
"messageRetention": 86400,
|
|
200
|
+
"deadLetterQueue": true,
|
|
201
|
+
"rateLimiting": {
|
|
202
|
+
"enabled": true,
|
|
203
|
+
"maxMessagesPerSecond": 1000,
|
|
204
|
+
"burstSize": 100
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
},
|
|
208
|
+
{
|
|
209
|
+
"name": "agents.code-reviewer.tasks",
|
|
210
|
+
"type": "direct",
|
|
211
|
+
"description": "Direct task assignments to code-reviewer agent",
|
|
212
|
+
"schema": "ReviewTask",
|
|
213
|
+
"qos": {
|
|
214
|
+
"deliveryMode": "exactly-once",
|
|
215
|
+
"persistent": true,
|
|
216
|
+
"ordered": true
|
|
217
|
+
},
|
|
218
|
+
"config": {
|
|
219
|
+
"maxMessageSize": 524288,
|
|
220
|
+
"messageRetention": 3600,
|
|
221
|
+
"encryption": {
|
|
222
|
+
"enabled": true,
|
|
223
|
+
"algorithm": "AES-256-GCM",
|
|
224
|
+
"keyRef": "messaging-encryption-key"
|
|
225
|
+
}
|
|
226
|
+
}
|
|
227
|
+
},
|
|
228
|
+
{
|
|
229
|
+
"name": "agents.broadcast.shutdown",
|
|
230
|
+
"type": "broadcast",
|
|
231
|
+
"description": "System-wide shutdown notification",
|
|
232
|
+
"schema": "SystemShutdown",
|
|
233
|
+
"qos": {
|
|
234
|
+
"deliveryMode": "at-most-once",
|
|
235
|
+
"persistent": false,
|
|
236
|
+
"ordered": false
|
|
237
|
+
},
|
|
238
|
+
"config": {
|
|
239
|
+
"maxMessageSize": 4096,
|
|
240
|
+
"messageRetention": 0,
|
|
241
|
+
"deadLetterQueue": false
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
]
|
|
245
|
+
}
|
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "https://openstandardagents.org/schemas/v0.3.1/messaging/delivery-receipt.json",
|
|
4
|
+
"title": "OSSA Delivery Receipt Schema",
|
|
5
|
+
"description": "Schema for message delivery receipts in OSSA v0.3.1",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": [
|
|
8
|
+
"messageId",
|
|
9
|
+
"status",
|
|
10
|
+
"timestamp"
|
|
11
|
+
],
|
|
12
|
+
"properties": {
|
|
13
|
+
"messageId": {
|
|
14
|
+
"type": "string",
|
|
15
|
+
"description": "Original message ID",
|
|
16
|
+
"pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
|
|
17
|
+
},
|
|
18
|
+
"receiptId": {
|
|
19
|
+
"type": "string",
|
|
20
|
+
"description": "Unique receipt identifier (UUID v4)",
|
|
21
|
+
"pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
|
|
22
|
+
},
|
|
23
|
+
"status": {
|
|
24
|
+
"type": "string",
|
|
25
|
+
"enum": [
|
|
26
|
+
"accepted",
|
|
27
|
+
"delivered",
|
|
28
|
+
"acknowledged",
|
|
29
|
+
"processed",
|
|
30
|
+
"failed",
|
|
31
|
+
"rejected",
|
|
32
|
+
"expired"
|
|
33
|
+
],
|
|
34
|
+
"description": "Delivery status"
|
|
35
|
+
},
|
|
36
|
+
"timestamp": {
|
|
37
|
+
"type": "string",
|
|
38
|
+
"description": "Receipt timestamp (ISO 8601 UTC)",
|
|
39
|
+
"format": "date-time"
|
|
40
|
+
},
|
|
41
|
+
"subscriber": {
|
|
42
|
+
"type": "string",
|
|
43
|
+
"description": "Subscriber agent ID",
|
|
44
|
+
"pattern": "^ossa://agents/[a-z0-9-]+$",
|
|
45
|
+
"examples": [
|
|
46
|
+
"ossa://agents/code-reviewer"
|
|
47
|
+
]
|
|
48
|
+
},
|
|
49
|
+
"channel": {
|
|
50
|
+
"type": "string",
|
|
51
|
+
"description": "Channel where message was delivered",
|
|
52
|
+
"pattern": "^agents\\.([a-z0-9-]+\\.)+[a-z0-9-]+$"
|
|
53
|
+
},
|
|
54
|
+
"deliveryAttempt": {
|
|
55
|
+
"type": "integer",
|
|
56
|
+
"description": "Delivery attempt number (1-based)",
|
|
57
|
+
"minimum": 1
|
|
58
|
+
},
|
|
59
|
+
"processingTime": {
|
|
60
|
+
"type": "integer",
|
|
61
|
+
"description": "Message processing time in milliseconds",
|
|
62
|
+
"minimum": 0
|
|
63
|
+
},
|
|
64
|
+
"error": {
|
|
65
|
+
"$ref": "#/definitions/DeliveryError",
|
|
66
|
+
"description": "Error details (only present when status is failed or rejected)"
|
|
67
|
+
},
|
|
68
|
+
"metadata": {
|
|
69
|
+
"type": "object",
|
|
70
|
+
"description": "Additional receipt metadata",
|
|
71
|
+
"additionalProperties": true
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
"additionalProperties": false,
|
|
75
|
+
"definitions": {
|
|
76
|
+
"DeliveryError": {
|
|
77
|
+
"type": "object",
|
|
78
|
+
"required": [
|
|
79
|
+
"code",
|
|
80
|
+
"message"
|
|
81
|
+
],
|
|
82
|
+
"properties": {
|
|
83
|
+
"code": {
|
|
84
|
+
"type": "string",
|
|
85
|
+
"description": "Error code",
|
|
86
|
+
"examples": [
|
|
87
|
+
"TIMEOUT",
|
|
88
|
+
"HANDLER_ERROR",
|
|
89
|
+
"VALIDATION_FAILED",
|
|
90
|
+
"SUBSCRIBER_UNAVAILABLE"
|
|
91
|
+
]
|
|
92
|
+
},
|
|
93
|
+
"message": {
|
|
94
|
+
"type": "string",
|
|
95
|
+
"description": "Human-readable error message",
|
|
96
|
+
"maxLength": 512
|
|
97
|
+
},
|
|
98
|
+
"details": {
|
|
99
|
+
"type": "object",
|
|
100
|
+
"description": "Additional error details",
|
|
101
|
+
"additionalProperties": true
|
|
102
|
+
},
|
|
103
|
+
"stackTrace": {
|
|
104
|
+
"type": "string",
|
|
105
|
+
"description": "Stack trace (only in development/debug mode)",
|
|
106
|
+
"maxLength": 4096
|
|
107
|
+
},
|
|
108
|
+
"retryable": {
|
|
109
|
+
"type": "boolean",
|
|
110
|
+
"default": true,
|
|
111
|
+
"description": "Whether delivery can be retried"
|
|
112
|
+
}
|
|
113
|
+
},
|
|
114
|
+
"additionalProperties": false
|
|
115
|
+
}
|
|
116
|
+
},
|
|
117
|
+
"examples": [
|
|
118
|
+
{
|
|
119
|
+
"messageId": "550e8400-e29b-41d4-a716-446655440000",
|
|
120
|
+
"receiptId": "660f9511-f3ac-52e5-b827-557766551111",
|
|
121
|
+
"status": "acknowledged",
|
|
122
|
+
"timestamp": "2025-12-18T14:32:16.234Z",
|
|
123
|
+
"subscriber": "ossa://agents/code-reviewer",
|
|
124
|
+
"channel": "agents.tasks.assigned",
|
|
125
|
+
"deliveryAttempt": 1,
|
|
126
|
+
"processingTime": 1234,
|
|
127
|
+
"metadata": {
|
|
128
|
+
"handlerName": "handleTaskAssigned",
|
|
129
|
+
"queueTime": 45
|
|
130
|
+
}
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
"messageId": "770e8400-e29b-41d4-a716-446655440001",
|
|
134
|
+
"receiptId": "880f9511-f3ac-52e5-b827-557766551112",
|
|
135
|
+
"status": "failed",
|
|
136
|
+
"timestamp": "2025-12-18T14:35:00.567Z",
|
|
137
|
+
"subscriber": "ossa://agents/code-reviewer",
|
|
138
|
+
"channel": "agents.tasks.assigned",
|
|
139
|
+
"deliveryAttempt": 3,
|
|
140
|
+
"processingTime": 30000,
|
|
141
|
+
"error": {
|
|
142
|
+
"code": "TIMEOUT",
|
|
143
|
+
"message": "Handler exceeded 30s timeout",
|
|
144
|
+
"details": {
|
|
145
|
+
"timeout": 30000,
|
|
146
|
+
"actualDuration": 30124
|
|
147
|
+
},
|
|
148
|
+
"retryable": true
|
|
149
|
+
}
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
"messageId": "990e8400-e29b-41d4-a716-446655440002",
|
|
153
|
+
"receiptId": "aa0f9511-f3ac-52e5-b827-557766551113",
|
|
154
|
+
"status": "rejected",
|
|
155
|
+
"timestamp": "2025-12-18T14:40:00.890Z",
|
|
156
|
+
"subscriber": "ossa://agents/code-reviewer",
|
|
157
|
+
"channel": "agents.tasks.assigned",
|
|
158
|
+
"deliveryAttempt": 1,
|
|
159
|
+
"processingTime": 15,
|
|
160
|
+
"error": {
|
|
161
|
+
"code": "VALIDATION_FAILED",
|
|
162
|
+
"message": "Message payload failed schema validation",
|
|
163
|
+
"details": {
|
|
164
|
+
"schemaErrors": [
|
|
165
|
+
{
|
|
166
|
+
"field": "payload.taskId",
|
|
167
|
+
"error": "Required field missing"
|
|
168
|
+
}
|
|
169
|
+
]
|
|
170
|
+
},
|
|
171
|
+
"retryable": false
|
|
172
|
+
}
|
|
173
|
+
},
|
|
174
|
+
{
|
|
175
|
+
"messageId": "bb0e8400-e29b-41d4-a716-446655440003",
|
|
176
|
+
"receiptId": "cc0f9511-f3ac-52e5-b827-557766551114",
|
|
177
|
+
"status": "expired",
|
|
178
|
+
"timestamp": "2025-12-18T15:32:15.123Z",
|
|
179
|
+
"channel": "agents.tasks.assigned",
|
|
180
|
+
"deliveryAttempt": 0,
|
|
181
|
+
"error": {
|
|
182
|
+
"code": "TTL_EXPIRED",
|
|
183
|
+
"message": "Message exceeded time-to-live",
|
|
184
|
+
"details": {
|
|
185
|
+
"ttl": 3600,
|
|
186
|
+
"messageAge": 3605
|
|
187
|
+
},
|
|
188
|
+
"retryable": false
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
]
|
|
192
|
+
}
|
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "https://openstandardagents.org/schemas/v0.3.1/messaging/message.json",
|
|
4
|
+
"title": "OSSA Message Schema",
|
|
5
|
+
"description": "Schema for Agent-to-Agent messages in OSSA v0.3.1",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"required": [
|
|
8
|
+
"id",
|
|
9
|
+
"channel",
|
|
10
|
+
"sender",
|
|
11
|
+
"timestamp",
|
|
12
|
+
"type",
|
|
13
|
+
"payload"
|
|
14
|
+
],
|
|
15
|
+
"properties": {
|
|
16
|
+
"id": {
|
|
17
|
+
"type": "string",
|
|
18
|
+
"description": "Unique message identifier (UUID v4)",
|
|
19
|
+
"pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
|
|
20
|
+
"examples": [
|
|
21
|
+
"550e8400-e29b-41d4-a716-446655440000"
|
|
22
|
+
]
|
|
23
|
+
},
|
|
24
|
+
"channel": {
|
|
25
|
+
"type": "string",
|
|
26
|
+
"description": "Target channel name (supports wildcards for subscriptions)",
|
|
27
|
+
"pattern": "^agents\\.(([a-z0-9-]+|\\*)\\.)+([a-z0-9-]+|#)$",
|
|
28
|
+
"minLength": 3,
|
|
29
|
+
"maxLength": 256,
|
|
30
|
+
"examples": [
|
|
31
|
+
"agents.tasks.assigned",
|
|
32
|
+
"agents.code-reviewer.completed",
|
|
33
|
+
"agents.broadcast.shutdown"
|
|
34
|
+
]
|
|
35
|
+
},
|
|
36
|
+
"sender": {
|
|
37
|
+
"type": "string",
|
|
38
|
+
"description": "Sender agent ID (OSSA URI format)",
|
|
39
|
+
"pattern": "^ossa://agents/[a-z0-9-]+$",
|
|
40
|
+
"examples": [
|
|
41
|
+
"ossa://agents/task-orchestrator",
|
|
42
|
+
"ossa://agents/code-reviewer"
|
|
43
|
+
]
|
|
44
|
+
},
|
|
45
|
+
"timestamp": {
|
|
46
|
+
"type": "string",
|
|
47
|
+
"description": "Message creation timestamp (ISO 8601 UTC)",
|
|
48
|
+
"format": "date-time",
|
|
49
|
+
"examples": [
|
|
50
|
+
"2025-12-18T14:32:15.123Z"
|
|
51
|
+
]
|
|
52
|
+
},
|
|
53
|
+
"type": {
|
|
54
|
+
"type": "string",
|
|
55
|
+
"description": "Message type identifier (PascalCase)",
|
|
56
|
+
"pattern": "^[A-Z][a-zA-Z0-9]*$",
|
|
57
|
+
"minLength": 1,
|
|
58
|
+
"maxLength": 64,
|
|
59
|
+
"examples": [
|
|
60
|
+
"TaskAssigned",
|
|
61
|
+
"TaskCompleted",
|
|
62
|
+
"StatusUpdate",
|
|
63
|
+
"ErrorOccurred"
|
|
64
|
+
]
|
|
65
|
+
},
|
|
66
|
+
"payload": {
|
|
67
|
+
"type": "object",
|
|
68
|
+
"description": "Message content (structure validated by type schema)",
|
|
69
|
+
"additionalProperties": true,
|
|
70
|
+
"examples": [
|
|
71
|
+
{
|
|
72
|
+
"taskId": "task-001",
|
|
73
|
+
"description": "Review PR #132"
|
|
74
|
+
}
|
|
75
|
+
]
|
|
76
|
+
},
|
|
77
|
+
"metadata": {
|
|
78
|
+
"$ref": "#/definitions/MessageMetadata",
|
|
79
|
+
"description": "Optional message metadata"
|
|
80
|
+
},
|
|
81
|
+
"qos": {
|
|
82
|
+
"$ref": "#/definitions/QualityOfService",
|
|
83
|
+
"description": "Delivery guarantees (defaults to at-least-once)"
|
|
84
|
+
}
|
|
85
|
+
},
|
|
86
|
+
"additionalProperties": false,
|
|
87
|
+
"definitions": {
|
|
88
|
+
"MessageMetadata": {
|
|
89
|
+
"type": "object",
|
|
90
|
+
"description": "Message metadata for routing and processing",
|
|
91
|
+
"properties": {
|
|
92
|
+
"correlationId": {
|
|
93
|
+
"type": "string",
|
|
94
|
+
"description": "Correlation ID for request-response patterns",
|
|
95
|
+
"minLength": 1,
|
|
96
|
+
"maxLength": 256
|
|
97
|
+
},
|
|
98
|
+
"replyTo": {
|
|
99
|
+
"type": "string",
|
|
100
|
+
"description": "Channel name for response messages",
|
|
101
|
+
"pattern": "^agents\\.([a-z0-9-]+\\.)+[a-z0-9-]+$"
|
|
102
|
+
},
|
|
103
|
+
"priority": {
|
|
104
|
+
"type": "string",
|
|
105
|
+
"enum": ["low", "normal", "high", "critical"],
|
|
106
|
+
"default": "normal",
|
|
107
|
+
"description": "Message priority for routing and processing"
|
|
108
|
+
},
|
|
109
|
+
"ttl": {
|
|
110
|
+
"type": "integer",
|
|
111
|
+
"description": "Time-to-live in seconds (message expires after this duration)",
|
|
112
|
+
"minimum": 1,
|
|
113
|
+
"maximum": 86400
|
|
114
|
+
},
|
|
115
|
+
"contentType": {
|
|
116
|
+
"type": "string",
|
|
117
|
+
"description": "MIME type of payload content",
|
|
118
|
+
"default": "application/json",
|
|
119
|
+
"examples": [
|
|
120
|
+
"application/json",
|
|
121
|
+
"application/xml",
|
|
122
|
+
"text/plain"
|
|
123
|
+
]
|
|
124
|
+
},
|
|
125
|
+
"contentEncoding": {
|
|
126
|
+
"type": "string",
|
|
127
|
+
"description": "Encoding of payload content",
|
|
128
|
+
"default": "utf-8",
|
|
129
|
+
"examples": [
|
|
130
|
+
"utf-8",
|
|
131
|
+
"base64",
|
|
132
|
+
"gzip"
|
|
133
|
+
]
|
|
134
|
+
},
|
|
135
|
+
"headers": {
|
|
136
|
+
"type": "object",
|
|
137
|
+
"description": "Custom headers for tracing, authentication, etc.",
|
|
138
|
+
"additionalProperties": {
|
|
139
|
+
"type": "string"
|
|
140
|
+
},
|
|
141
|
+
"examples": [
|
|
142
|
+
{
|
|
143
|
+
"traceparent": "00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01",
|
|
144
|
+
"user-agent": "OSSA/0.3.1"
|
|
145
|
+
}
|
|
146
|
+
]
|
|
147
|
+
}
|
|
148
|
+
},
|
|
149
|
+
"additionalProperties": false
|
|
150
|
+
},
|
|
151
|
+
"QualityOfService": {
|
|
152
|
+
"type": "object",
|
|
153
|
+
"description": "Message delivery guarantees",
|
|
154
|
+
"properties": {
|
|
155
|
+
"deliveryMode": {
|
|
156
|
+
"type": "string",
|
|
157
|
+
"enum": ["at-most-once", "at-least-once", "exactly-once"],
|
|
158
|
+
"default": "at-least-once",
|
|
159
|
+
"description": "Delivery guarantee level"
|
|
160
|
+
},
|
|
161
|
+
"persistent": {
|
|
162
|
+
"type": "boolean",
|
|
163
|
+
"default": true,
|
|
164
|
+
"description": "Whether message survives broker restarts"
|
|
165
|
+
},
|
|
166
|
+
"ordered": {
|
|
167
|
+
"type": "boolean",
|
|
168
|
+
"default": true,
|
|
169
|
+
"description": "Whether message order is preserved within channel"
|
|
170
|
+
}
|
|
171
|
+
},
|
|
172
|
+
"additionalProperties": false
|
|
173
|
+
}
|
|
174
|
+
},
|
|
175
|
+
"examples": [
|
|
176
|
+
{
|
|
177
|
+
"id": "550e8400-e29b-41d4-a716-446655440000",
|
|
178
|
+
"channel": "agents.tasks.assigned",
|
|
179
|
+
"sender": "ossa://agents/task-orchestrator",
|
|
180
|
+
"timestamp": "2025-12-18T14:32:15.123Z",
|
|
181
|
+
"type": "TaskAssigned",
|
|
182
|
+
"payload": {
|
|
183
|
+
"taskId": "task-001",
|
|
184
|
+
"assignedTo": "ossa://agents/code-reviewer",
|
|
185
|
+
"description": "Review PR #132",
|
|
186
|
+
"priority": "high",
|
|
187
|
+
"deadline": "2025-12-18T18:00:00Z"
|
|
188
|
+
},
|
|
189
|
+
"metadata": {
|
|
190
|
+
"correlationId": "pr-132",
|
|
191
|
+
"replyTo": "agents.orchestrator.responses",
|
|
192
|
+
"priority": "high",
|
|
193
|
+
"ttl": 3600,
|
|
194
|
+
"headers": {
|
|
195
|
+
"traceparent": "00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01"
|
|
196
|
+
}
|
|
197
|
+
},
|
|
198
|
+
"qos": {
|
|
199
|
+
"deliveryMode": "at-least-once",
|
|
200
|
+
"persistent": true,
|
|
201
|
+
"ordered": true
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
]
|
|
205
|
+
}
|