CONTENT CONTRACT · VERSION 1
binding
A filtered event subscription with one owner source and an explicit snapshot.
Signature
{ event: EventKind, filter: EventFilter, id: ContentId, kind: "binding", owner_from: BindingOwner, parameters: Parameters, script: ScriptId, snapshot: SnapshotSpec }Fields
| Name | Type | Meaning |
|---|---|---|
event | EventKind | Event kind or typed event payload selected by the handler declaration. |
filter | EventFilter | Definition references that restrict which matching events invoke the binding. |
id | ContentId | Package-qualified identity; unique within its declaring namespace. Length: 1…129; Pattern: ^[a-z][a-z0-9_]{0,31}:[a-z][a-z0-9_]{0,95}$ |
kind | "binding" | Discriminant |
owner_from | BindingOwner | Event field that supplies the invocation owner. |
parameters | Parameters | Exact closed argument record supplied by the selected definition. |
script | ScriptId | Authority handler declared by the same package. Length: 1…129; Pattern: ^[a-z][a-z0-9_]{0,31}:[a-z][a-z0-9_]{0,95}$; Reference: script |
snapshot | SnapshotSpec | Explicit visibility requested for the frozen invocation snapshot. |
Validated example
{
"event": "dialogue_choice",
"filter": {
"choice": "accept",
"dialogue": "core:milo_talk",
"node": "offer"
},
"id": "core:a_place_to_rest_accept",
"kind": "binding",
"owner_from": "player",
"parameters": {
"quest": "core:a_place_to_rest"
},
"script": "core:quest_accept",
"snapshot": {
"anchors": [],
"definitions_from": [
"core"
],
"radius_mm": 0,
"variables": []
}
}