Files
gstack/schemas/completion.schema.json
T
Garry Tan 1829f60596 feat: add JSON Schema definitions + COMPATIBILITY.md for cross-runtime contracts
Four schemas for the OpenClaw dispatch protocol:
- dispatch.schema.json (task dispatch with target_agent, source_signature)
- completion.schema.json (session completion report with retry_count)
- handoff.schema.json (cross-runtime context transfer with resume_prompt)
- activity-entry.schema.json (weekly activity index entries)

COMPATIBILITY.md defines breaking vs non-breaking changes so future
contributors don't guess under pressure.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-04 21:24:22 -07:00

20 lines
1.0 KiB
JSON

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://github.com/garrytan/gstack/schemas/completion.schema.json",
"title": "gstack Dispatch Completion",
"description": "Completion report from a gstack coding session back to the orchestrator",
"type": "object",
"required": ["dispatch_id", "status", "duration"],
"properties": {
"dispatch_id": { "type": "string", "pattern": "^dispatch-" },
"status": { "enum": ["completed", "failed", "cancelled", "timeout"] },
"duration": { "type": "integer", "description": "Session duration in seconds" },
"commits": { "type": "integer", "minimum": 0 },
"pr": { "type": "string", "description": "PR reference in owner/repo#number format" },
"error": { "type": "string", "description": "Error description, present only on failure/timeout" },
"retry_count": { "type": "integer", "minimum": 0, "description": "Number of retries attempted" },
"target_agent": { "enum": ["claude", "codex", "cursor", "gemini"] }
},
"additionalProperties": false
}