{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://b2base.eu/schemas/1.0.0-draft.1/process/handoff.schema.json", "title": "Workflowübergaben", "$comment": "B2Base 1.0.0-draft.1. Projektentwurf, kein durch ISO oder andere Normungsgremien verabschiedeter Standard.", "type": "object", "description": "Ein Übergabeauftrag; keine automatische Ausführung.", "properties": { "id": { "type": "string", "minLength": 1, "description": "Eindeutige Übergabekennung; Empfänger soll Wiederholungen anhand dieser ID erkennen.", "format": "uri" }, "kind": { "type": "string", "minLength": 1, "description": "Art des Zielsystems.", "enum": [ "workflow", "email", "script" ] }, "target": { "type": "string", "minLength": 1, "description": "HTTPS-Ziel oder mailto-URI je nach kind; keine Zugangsdaten oder Tokens in der URI.", "format": "uri" }, "sourceWorkflowId": { "type": "string", "minLength": 1, "description": "Kennung des sendenden Workflowlaufs.", "format": "uri" }, "payload": { "type": "object", "description": "Explizit freigegebene Nutzdaten.", "properties": { "schemaId": { "type": "string", "minLength": 1, "description": "Schema der data-Nutzdaten.", "format": "uri" }, "data": { "type": "object", "description": "Fachdaten; gegen schemaId gesondert vollständig validieren.", "additionalProperties": true }, "taskRefs": { "type": "array", "description": "Aufgabenreferenzen.", "items": { "type": "string", "minLength": 1, "description": "Aufgaben-URI.", "format": "uri" } }, "documentRefs": { "type": "array", "description": "Dokumentreferenzen.", "items": { "type": "string", "minLength": 1, "description": "Dokument-URI.", "format": "uri" } } }, "required": [ "schemaId", "data" ], "additionalProperties": false }, "createdAt": { "type": "string", "minLength": 1, "description": "Zeitpunkt der Auftragserstellung.", "format": "date-time" }, "extensions": { "type": "object", "description": "Vereinbarte Erweiterungen; Schlüssel als absolute URI des Herausgebers. Keine stillschweigende Änderung von Kernfeldern.", "properties": {}, "additionalProperties": true, "propertyNames": { "format": "uri" } } }, "required": [ "id", "kind", "target", "payload" ], "additionalProperties": false, "allOf": [ { "if": { "properties": { "kind": { "const": "email" } }, "required": [ "kind" ] }, "then": { "properties": { "target": { "pattern": "^mailto:[^?]+" } } } }, { "if": { "properties": { "kind": { "enum": [ "workflow", "script" ] } }, "required": [ "kind" ] }, "then": { "properties": { "target": { "pattern": "^https://" } } } } ], "examples": [ { "id": "urn:example:handoff:42", "kind": "workflow", "target": "https://example.org/workflows/review", "payload": { "schemaId": "https://b2base.eu/schemas/1.0.0-draft.1/financial/money.schema.json", "data": { "amount": "125.00", "currency": "EUR" } } }, { "id": "urn:example:handoff:43", "kind": "email", "target": "mailto:workflow@example.org", "payload": { "schemaId": "https://b2base.eu/schemas/1.0.0-draft.1/person/nameandbirthdetails.schema.json", "data": { "name": { "preferredName": "Sukarno" } } } } ] }