{
  "definitions": {
    "timestampType": {
      "type": "string",
      "pattern": "^[0-9]{8}([T])[0-9]{6}\\.[0-9]{3,9}$"
    },
    "unsigned": {
      "type": "number",
      "multipleOf": 1,
      "minimum": 0,
      "maximum": 9223372036854775807
    },
    "text": {
      "type": "string",
      "pattern": "((?![|\"@,])[\\x20-\\x7E])"
    }
  },
  "$schema": "http://json-schema.org/draft-07/schema#",
  "title": "outstanding rejections feedback data file schema",
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "type": {
      "type": "string",
      "enum": [
          "FDIDRejection",
          "CustomerRejection"
      ]
    },
    "rejectedFDID": {
      "$ref": "#/definitions/text",
      "maxLength": 40
    },
    "submissionFilename": {
      "type": "string"
    },
    "submissionID": {
      "$ref": "#/definitions/unsigned"
    },
    "rejectionID": {
      "$ref": "#/definitions/unsigned"
    },
    "rejectionTimestamp": {
      "$ref": "#/definitions/timestampType"
    },
    "fdidRecordID": {
      "$ref": "#/definitions/unsigned"
    },
    "errorCode": {
      "$ref": "#/definitions/unsigned"
    },
    "customerRejectionEventID": {
      "type": "string",
      "maxLength": 100
    },
    "customerRecordID": {
      "type": "array",
      "items": {
        "$ref": "#/definitions/unsigned"
      }
    },
    "largeTraderRecordID": {
      "$ref": "#/definitions/unsigned"
    },
    "addrType": {
        "type": "string",
        "enum": [
            "ADDRESS1",
            "ADDRESS2",
            "ADDRESS3",
            "ADDRESS4"
        ]
    },
    "authTraderNameID": {
      "$ref": "#/definitions/unsigned"
    }
  },
  "required": [
    "type",
    "submissionFilename",
    "submissionID",
    "rejectionID",
    "rejectionTimestamp",
    "errorCode"
  ]
}