{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://decisions.coulomb.social/schemas/memo-intake.schema.json", "title": "informed-decision memo intake envelope v1", "description": "POST /v1/memos body (docs/specs/FrictionlessDecisionIntake.md \u00a73.2). The submitter comes from the verified workload token, never from this body. informed_decision/intake.py is the enforcing validator; this schema documents the shape.", "type": "object", "additionalProperties": false, "required": [ "kind", "version", "idempotency_key", "memo_class", "review_group", "approval_intent", "memo", "packet" ], "properties": { "kind": { "const": "informed-decision.memo-intake" }, "version": { "const": 1 }, "idempotency_key": { "type": "string", "pattern": "^[A-Za-z0-9._:-]{8,128}$" }, "memo_class": { "type": "string", "pattern": "^[a-z0-9][a-z0-9-]{1,62}$" }, "review_group": { "type": "string", "pattern": "^[a-z0-9][a-z0-9-]{1,62}$" }, "drafted_by": { "type": "string", "maxLength": 200, "description": "Asserted provenance, shown as such; not an identity." }, "serves": { "type": "object", "additionalProperties": false, "required": [ "hub_decision_id", "resolves" ], "properties": { "hub_decision_id": { "type": "string", "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$" }, "resolves": { "enum": [ "on-answer", "never" ] } } }, "approval_intent": { "type": "object", "additionalProperties": false, "required": [ "action", "principal", "purpose", "target" ], "description": "binding.actor is not accepted; intake sets it to informed-decision.", "properties": { "action": { "type": "string" }, "principal": { "type": "string" }, "purpose": { "type": "string" }, "target": { "type": "object", "additionalProperties": false, "required": [ "id", "type", "system" ], "properties": { "id": { "type": "string" }, "type": { "type": "string" }, "system": { "type": "string" } } } } }, "memo": { "type": "object", "description": "Unsigned draft in the operational shape read by informed_decision.records.memo_from: version 1, sealed false, approval_id and approval_binding_digest null, binding.principal.id pending-human-session." }, "packet": { "type": "array", "minItems": 1, "items": { "type": "object", "additionalProperties": false, "required": [ "item_id", "media_type", "content" ], "properties": { "item_id": { "type": "string" }, "media_type": { "enum": [ "text/markdown", "text/plain", "application/json" ] }, "content": { "type": "string", "maxLength": 262144 } } } } } }