{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/infinihash-com/json-schema/infinihash-com-signoff-result-schema.json",
  "title": "SignoffResult",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/infinihash-com-approvals-api-openapi.yml#/components/schemas/SignoffResult",
  "type": "object",
  "required": [
    "signoff",
    "submissionStatus"
  ],
  "properties": {
    "signoff": {
      "$ref": "#/$defs/ApprovalSignoff"
    },
    "submissionStatus": {
      "type": [
        "string",
        "null"
      ],
      "enum": [
        "approved",
        "rejected",
        null
      ],
      "description": "`rejected` after any rejection, `approved` once line1 and line2 have both approved, otherwise null (still pending the other line)."
    }
  },
  "$defs": {
    "ApprovalSignoff": {
      "type": "object",
      "required": [
        "id",
        "submissionId",
        "apiKeyId",
        "role",
        "approverName",
        "decision",
        "createdAt"
      ],
      "properties": {
        "id": {
          "type": "string"
        },
        "submissionId": {
          "type": "string"
        },
        "apiKeyId": {
          "type": "string"
        },
        "role": {
          "type": "string",
          "enum": [
            "line1",
            "line2"
          ]
        },
        "approverName": {
          "type": "string"
        },
        "approverEmail": {
          "type": [
            "string",
            "null"
          ]
        },
        "decision": {
          "type": "string",
          "enum": [
            "approve",
            "reject"
          ]
        },
        "notes": {
          "type": [
            "string",
            "null"
          ]
        },
        "createdAt": {
          "type": "string",
          "format": "date-time"
        }
      }
    }
  }
}