Workspace Intelligence / JSON Schema
Workspai Decision Event
Defines the versioned decision event v1 boundary used by Workspai and its consumers.
- Schema version
workspai.decision-event.v1- Contract path
contracts/workspace-intelligence/decision-event.v1.json- Publication
- json-schema
- Defined fields
- 60
- Artifact bindings
- 0
Why this contract exists
Architecture role
Defines a versioned interoperability boundary used by Workspai and contract-aware consumers.
Consumption boundary
- • Workspai CLI
- • Workspace Intelligence consumers
- • IDEs and agents
Related commands
Commands are linked only when the runtime contract identifies a direct production relationship. Supporting contracts may be consumed without having a single producer command.
This is a supporting, capability, cache, compatibility, or consumer contract. It has no single direct producer command in the canonical Workspace Intelligence execution registry.
Produced artifacts
These durable files are emitted by registered commands and validated against this contract.
No canonical file artifact is registered for this contract. It may describe capabilities, embedded data, runtime exchange, or supporting state instead of a standalone report.
Field reference
Every declared schema property or published capability path is listed here. Required means the contract declares or publishes that field at the shown boundary.
| Field path | Type | Required | Meaning | Constraints |
|---|---|---|---|---|
| $defs.artifactReference.artifact | string | Yes | Defines the artifact value at this contract boundary. | minLength: 1 |
| $defs.artifactReference.digest | reference | Yes | Defines the digest value at this contract boundary. | ref: #/$defs/digest |
| $defs.artifactReference.role | string | Yes | Defines the role value at this contract boundary. | minLength: 1 |
| $defs.artifactReference.schemaVersion | string | Yes | Defines the schemaversion value at this contract boundary. | minLength: 1 |
| $defs.authorization.effectClasses | array | Yes | Defines the effectclasses value at this contract boundary. | minItems: 1 |
| $defs.authorization.grant | enum | Yes | Defines the grant value at this contract boundary. | enum: bounded-effects, verification-only |
| $defs.authorization.grantedBy | string | Yes | Defines the grantedby value at this contract boundary. | minLength: 1 |
| $defs.blocker.actionable | boolean | Yes | Defines the actionable value at this contract boundary. | — |
| $defs.blocker.code | string | Yes | Defines the code value at this contract boundary. | minLength: 1 |
| $defs.blocker.details | string | No | Defines the details value at this contract boundary. | — |
| $defs.deletedArtifactReference.artifact | string | Yes | Defines the artifact value at this contract boundary. | minLength: 1 |
| $defs.deletedArtifactReference.digest | object | Yes | Defines the digest value at this contract boundary. | additionalProperties: false |
| $defs.deletedArtifactReference.digest.algorithm | string | Yes | Defines the algorithm value at this contract boundary. | const: "sha256" |
| $defs.deletedArtifactReference.digest.semantics | string | Yes | Defines the semantics value at this contract boundary. | const: "deletion-tombstone-v1" |
| $defs.deletedArtifactReference.digest.value | reference | Yes | Defines the value value at this contract boundary. | ref: #/$defs/sha256 |
| $defs.deletedArtifactReference.observedAt | string | Yes | Defines the observedat value at this contract boundary. | format: date-time |
| $defs.digest.algorithm | string | Yes | Defines the algorithm value at this contract boundary. | const: "sha256" |
| $defs.digest.semantics | enum | Yes | Defines the semantics value at this contract boundary. | enum: canonical-json-v1, raw-bytes-v1, workspace-model-structural-v1 |
| $defs.digest.value | reference | Yes | Defines the value value at this contract boundary. | ref: #/$defs/sha256 |
| $defs.effectReceipt.artifacts | array | Yes | Defines the artifacts value at this contract boundary. | — |
| $defs.effectReceipt.command | array | No | Defines the command value at this contract boundary. | minItems: 1 |
| $defs.effectReceipt.deletedArtifacts | array | No | Defines the deletedartifacts value at this contract boundary. | — |
| $defs.effectReceipt.effectClass | enum | Yes | Defines the effectclass value at this contract boundary. | enum: filesystem, command, configuration, dependency, external |
| $defs.effectReceipt.id | string | Yes | Defines the id value at this contract boundary. | minLength: 1 |
| $defs.effectReceipt.idempotencyKey | string | Yes | Defines the idempotencykey value at this contract boundary. | minLength: 1 |
| $defs.effectReceipt.observedAt | string | Yes | Defines the observedat value at this contract boundary. | format: date-time |
| $defs.effectReceipt.status | enum | Yes | Defines the status value at this contract boundary. | enum: succeeded, failed, uncertain |
| $defs.effectReceipt.summary | string | Yes | Defines the summary value at this contract boundary. | minLength: 1 |
| $defs.payload.authorization | reference | No | Defines the authorization value at this contract boundary. | ref: #/$defs/authorization |
| $defs.payload.blocker | reference | No | Defines the blocker value at this contract boundary. | ref: #/$defs/blocker |
| $defs.payload.effect | reference | No | Defines the effect value at this contract boundary. | ref: #/$defs/effectReceipt |
| $defs.payload.reason | string | No | Defines the reason value at this contract boundary. | — |
| $defs.payload.references | array | No | Defines the references value at this contract boundary. | — |
| $defs.payload.resumeTo | enum | No | Defines the resumeto value at this contract boundary. | enum: authorized, executing, verifying |
| $defs.payload.scope | reference | No | Defines the scope value at this contract boundary. | ref: #/$defs/scope |
| $defs.payload.summary | string | Yes | Defines the summary value at this contract boundary. | minLength: 1 |
| $defs.payload.verification | reference | No | Defines the verification value at this contract boundary. | ref: #/$defs/verificationReceipt |
| $defs.scope.kind | enum | Yes | Defines the kind value at this contract boundary. | enum: workspace, project, project-set |
| $defs.scope.projects | array | Yes | Defines the projects value at this contract boundary. | — |
| $defs.verificationReceipt.artifacts | array | Yes | Defines the artifacts value at this contract boundary. | — |
| $defs.verificationReceipt.criterionId | string | Yes | Defines the criterionid value at this contract boundary. | minLength: 1 |
| $defs.verificationReceipt.id | string | Yes | Defines the id value at this contract boundary. | minLength: 1 |
| $defs.verificationReceipt.observedAt | string | Yes | Defines the observedat value at this contract boundary. | format: date-time |
| $defs.verificationReceipt.status | enum | Yes | Defines the status value at this contract boundary. | enum: passed, failed, inconclusive |
| $defs.verificationReceipt.summary | string | Yes | Defines the summary value at this contract boundary. | minLength: 1 |
| $defs.verificationReceipt.target | object | Yes | Defines the target value at this contract boundary. | additionalProperties: false |
| $defs.verificationReceipt.target.effectHeadDigest | reference | Yes | Defines the effectheaddigest value at this contract boundary. | ref: #/$defs/sha256 |
| $defs.verificationReceipt.target.graphHash | reference | Yes | Defines the graphhash value at this contract boundary. | ref: #/$defs/sha256 |
| $defs.verificationReceipt.target.modelHash | reference | Yes | Defines the modelhash value at this contract boundary. | ref: #/$defs/sha256 |
| actor | object | Yes | Defines the actor value at this contract boundary. | additionalProperties: false |
| actor.id | string | Yes | Defines the id value at this contract boundary. | minLength: 1 |
| actor.kind | enum | Yes | Defines the kind value at this contract boundary. | enum: human, agent, cli, ci, extension |
| digest | reference | Yes | Defines the digest value at this contract boundary. | ref: #/$defs/sha256 |
| kind | enum | Yes | Defines the kind value at this contract boundary. | enum: created, scope-bound, evidence-attached, plan-attached, authorized, effect-requested, effect-recorded, effect-uncertain, verification-started, verification-recorded, human-required, blocked, resumed, committed, rejected, aborted, superseded |
| occurredAt | string | Yes | Defines the occurredat value at this contract boundary. | format: date-time |
| payload | reference | Yes | Defines the payload value at this contract boundary. | ref: #/$defs/payload |
| previousEventDigest | any | Yes | Defines the previouseventdigest value at this contract boundary. | — |
| schemaVersion | string | Yes | Defines the schemaversion value at this contract boundary. | const: "workspai.decision-event.v1" |
| sequence | integer | Yes | Defines the sequence value at this contract boundary. | minimum: 1 |
| transactionId | string | Yes | Defines the transactionid value at this contract boundary. | pattern: ^change-[a-z0-9][a-z0-9-]{7,95}$ |
Canonical machine-readable definition
The raw synchronized contract remains authoritative. The educational sections above are projections of this definition.
Show raw JSON
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://workspai.dev/schemas/workspace-intelligence/decision-event.v1.json",
"title": "Workspai Decision Event",
"type": "object",
"required": [
"schemaVersion",
"transactionId",
"sequence",
"kind",
"occurredAt",
"actor",
"previousEventDigest",
"payload",
"digest"
],
"properties": {
"schemaVersion": {
"const": "workspai.decision-event.v1"
},
"transactionId": {
"type": "string",
"pattern": "^change-[a-z0-9][a-z0-9-]{7,95}$"
},
"sequence": {
"type": "integer",
"minimum": 1
},
"kind": {
"enum": [
"created",
"scope-bound",
"evidence-attached",
"plan-attached",
"authorized",
"effect-requested",
"effect-recorded",
"effect-uncertain",
"verification-started",
"verification-recorded",
"human-required",
"blocked",
"resumed",
"committed",
"rejected",
"aborted",
"superseded"
]
},
"occurredAt": {
"type": "string",
"format": "date-time"
},
"actor": {
"type": "object",
"required": [
"kind",
"id"
],
"properties": {
"kind": {
"enum": [
"human",
"agent",
"cli",
"ci",
"extension"
]
},
"id": {
"type": "string",
"minLength": 1
}
},
"additionalProperties": false
},
"previousEventDigest": {
"oneOf": [
{
"$ref": "#/$defs/sha256"
},
{
"type": "null"
}
]
},
"payload": {
"$ref": "#/$defs/payload"
},
"digest": {
"$ref": "#/$defs/sha256"
}
},
"additionalProperties": false,
"$defs": {
"sha256": {
"type": "string",
"pattern": "^[a-f0-9]{64}$"
},
"digest": {
"type": "object",
"required": [
"algorithm",
"semantics",
"value"
],
"properties": {
"algorithm": {
"const": "sha256"
},
"semantics": {
"enum": [
"canonical-json-v1",
"raw-bytes-v1",
"workspace-model-structural-v1"
]
},
"value": {
"$ref": "#/$defs/sha256"
}
},
"additionalProperties": false
},
"artifactReference": {
"type": "object",
"required": [
"role",
"artifact",
"schemaVersion",
"digest"
],
"properties": {
"role": {
"type": "string",
"minLength": 1
},
"artifact": {
"type": "string",
"minLength": 1
},
"schemaVersion": {
"type": "string",
"minLength": 1
},
"digest": {
"$ref": "#/$defs/digest"
}
},
"additionalProperties": false
},
"deletedArtifactReference": {
"type": "object",
"required": [
"artifact",
"observedAt",
"digest"
],
"properties": {
"artifact": {
"type": "string",
"minLength": 1
},
"observedAt": {
"type": "string",
"format": "date-time"
},
"digest": {
"type": "object",
"required": [
"algorithm",
"semantics",
"value"
],
"properties": {
"algorithm": {
"const": "sha256"
},
"semantics": {
"const": "deletion-tombstone-v1"
},
"value": {
"$ref": "#/$defs/sha256"
}
},
"additionalProperties": false
}
},
"additionalProperties": false
},
"scope": {
"type": "object",
"required": [
"kind",
"projects"
],
"properties": {
"kind": {
"enum": [
"workspace",
"project",
"project-set"
]
},
"projects": {
"type": "array",
"items": {
"type": "string",
"minLength": 1
},
"uniqueItems": true
}
},
"additionalProperties": false
},
"authorization": {
"type": "object",
"required": [
"grantedBy",
"grant",
"effectClasses"
],
"properties": {
"grantedBy": {
"type": "string",
"minLength": 1
},
"grant": {
"enum": [
"bounded-effects",
"verification-only"
]
},
"effectClasses": {
"type": "array",
"items": {
"enum": [
"filesystem",
"command",
"configuration",
"dependency",
"external"
]
},
"minItems": 1,
"uniqueItems": true
}
},
"additionalProperties": false
},
"effectReceipt": {
"type": "object",
"required": [
"id",
"effectClass",
"status",
"summary",
"artifacts",
"observedAt",
"idempotencyKey"
],
"properties": {
"id": {
"type": "string",
"minLength": 1
},
"effectClass": {
"enum": [
"filesystem",
"command",
"configuration",
"dependency",
"external"
]
},
"status": {
"enum": [
"succeeded",
"failed",
"uncertain"
]
},
"summary": {
"type": "string",
"minLength": 1
},
"command": {
"type": "array",
"items": {
"type": "string"
},
"minItems": 1
},
"artifacts": {
"type": "array",
"items": {
"$ref": "#/$defs/artifactReference"
}
},
"deletedArtifacts": {
"type": "array",
"items": {
"$ref": "#/$defs/deletedArtifactReference"
},
"uniqueItems": true
},
"observedAt": {
"type": "string",
"format": "date-time"
},
"idempotencyKey": {
"type": "string",
"minLength": 1
}
},
"additionalProperties": false
},
"verificationReceipt": {
"type": "object",
"required": [
"id",
"criterionId",
"status",
"summary",
"target",
"artifacts",
"observedAt"
],
"properties": {
"id": {
"type": "string",
"minLength": 1
},
"criterionId": {
"type": "string",
"minLength": 1
},
"status": {
"enum": [
"passed",
"failed",
"inconclusive"
]
},
"summary": {
"type": "string",
"minLength": 1
},
"target": {
"type": "object",
"required": [
"modelHash",
"graphHash",
"effectHeadDigest"
],
"properties": {
"modelHash": {
"$ref": "#/$defs/sha256"
},
"graphHash": {
"$ref": "#/$defs/sha256"
},
"effectHeadDigest": {
"$ref": "#/$defs/sha256"
}
},
"additionalProperties": false
},
"artifacts": {
"type": "array",
"items": {
"$ref": "#/$defs/artifactReference"
}
},
"observedAt": {
"type": "string",
"format": "date-time"
}
},
"additionalProperties": false
},
"blocker": {
"type": "object",
"required": [
"code",
"actionable"
],
"properties": {
"code": {
"type": "string",
"minLength": 1
},
"actionable": {
"type": "boolean"
},
"details": {
"type": "string"
}
},
"additionalProperties": false
},
"payload": {
"type": "object",
"required": [
"summary"
],
"properties": {
"summary": {
"type": "string",
"minLength": 1
},
"scope": {
"$ref": "#/$defs/scope"
},
"references": {
"type": "array",
"items": {
"$ref": "#/$defs/artifactReference"
}
},
"authorization": {
"$ref": "#/$defs/authorization"
},
"effect": {
"$ref": "#/$defs/effectReceipt"
},
"verification": {
"$ref": "#/$defs/verificationReceipt"
},
"blocker": {
"$ref": "#/$defs/blocker"
},
"resumeTo": {
"enum": [
"authorized",
"executing",
"verifying"
]
},
"reason": {
"type": "string"
}
},
"additionalProperties": false
}
}
}