{
  "oneOf": [
    {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "recordId": {
          "type": "string",
          "minLength": 1,
          "maxLength": 512,
          "pattern": "^[^\\s]+$"
        },
        "index": {
          "type": "integer",
          "minimum": 0,
          "maximum": 99
        },
        "correlationId": {
          "type": "string",
          "minLength": 1,
          "maxLength": 512,
          "pattern": "^[^\\s]+$"
        },
        "outcome": {
          "type": "string",
          "enum": [
            "success"
          ]
        },
        "record": {
          "$ref": "#/components/schemas/ProjectAgentRecord"
        },
        "etag": {
          "type": "string",
          "pattern": "^\"[^\"\\s]+:v[1-9][0-9]*\"$"
        }
      },
      "required": [
        "recordId",
        "index",
        "correlationId",
        "outcome",
        "record",
        "etag"
      ]
    },
    {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "recordId": {
          "type": "string",
          "minLength": 1,
          "maxLength": 512,
          "pattern": "^[^\\s]+$"
        },
        "index": {
          "type": "integer",
          "minimum": 0,
          "maximum": 99
        },
        "correlationId": {
          "type": "string",
          "minLength": 1,
          "maxLength": 512,
          "pattern": "^[^\\s]+$"
        },
        "outcome": {
          "type": "string",
          "enum": [
            "conflict",
            "validation",
            "denied"
          ]
        },
        "error": {
          "$ref": "#/components/schemas/ProjectAgentError"
        }
      },
      "required": [
        "recordId",
        "index",
        "correlationId",
        "outcome",
        "error"
      ]
    }
  ]
}