{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://openeik.org/schemas/0.5/commands/edge.attach.schema.json",
  "$comment": "OpenEik 0.5: folded by tools/fold-schemas-0.5.mjs from the proposal domainCommands, which 0.5 makes a rule (open questions, 139). Written by hand, not generated.",
  "title": "edge.attach",
  "description": "Trims an edge of a slab's, a foundation's, a ceiling's or a roof's outline to a wall's face, or lets it go (Part V, 2.3.1, rule 14; Part II, 6.7): the edge's entry of edgeAttachments is replaced by {edgeId, hostId, face}, or taken away where hostId is null. Run as an update.",
  "type": "object",
  "properties": {
    "kind": {
      "const": "edge.attach"
    },
    "id": {
      "type": "string",
      "minLength": 1,
      "x-eik-ref": "element"
    },
    "expectedRevision": {
      "type": "integer",
      "minimum": 0,
      "description": "The element's revision as read."
    },
    "edgeId": {
      "type": "string",
      "minLength": 1,
      "description": "The edge, by its id (Part I, 6.6)."
    },
    "hostId": {
      "anyOf": [
        {
          "type": "string",
          "minLength": 1,
          "x-eik-ref": "element"
        },
        {
          "type": "null"
        }
      ],
      "description": "The wall; null lets the edge go."
    },
    "expectedHostRevision": {
      "type": "integer",
      "minimum": 0,
      "description": "The wall's revision as read; given with a wall."
    },
    "face": {
      "type": "string",
      "enum": [
        "interior",
        "exterior"
      ],
      "description": "interior where it is left out."
    }
  },
  "required": [
    "kind",
    "id",
    "expectedRevision",
    "edgeId",
    "hostId"
  ],
  "additionalProperties": false
}
