{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/openpayments-io/main/json-schema/openpayments-io-confirm-iso-payment-response-schema.json",
  "title": "ConfirmIsoPaymentResponse",
  "description": "Response containing information on the payment file uploaded to the bank. ",
  "x-generated": "2026-10-16",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/openpayments-io-openapi.yml#/components/schemas/ConfirmIsoPaymentResponse",
  "type": "object",
  "properties": {
    "tppMessages": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "#/$defs/tppMessage2XX"
      }
    },
    "reference": {
      "type": [
        "string",
        "null"
      ]
    },
    "totalAmount": {
      "$ref": "#/$defs/amount"
    }
  },
  "additionalProperties": false,
  "$defs": {
    "MessageCode2XX": {
      "description": "Message codes for HTTP Error codes 2XX.",
      "type": "string"
    },
    "amount": {
      "type": "object",
      "required": [
        "currency",
        "amount"
      ],
      "properties": {
        "currency": {
          "$ref": "#/$defs/currencyCode"
        },
        "amount": {
          "$ref": "#/$defs/amountValue"
        }
      }
    },
    "amountValue": {
      "description": "The amount given with fractional digits, where fractions must be compliant to the currency definition.\nUp to 14 significant figures. Negative amounts are signed by minus.\nThe decimal separator is a dot.\n\n**Example:**\nValid representations for EUR with up to two decimals are:\n\n  * 1056\n  * 5768.2\n  * -1.50\n  * 5877.78\n",
      "type": "string",
      "pattern": "-?[0-9]{1,14}(\\.[0-9]{1,3})?"
    },
    "currencyCode": {
      "description": "ISO 4217 Alpha 3 currency code.\n",
      "type": "string",
      "pattern": "[A-Z]{3}"
    },
    "tppMessage2XX": {
      "type": "object",
      "required": [
        "category",
        "code"
      ],
      "properties": {
        "category": {
          "$ref": "#/$defs/tppMessageCategory"
        },
        "code": {
          "$ref": "#/$defs/MessageCode2XX"
        },
        "path": {
          "type": "string"
        },
        "text": {
          "$ref": "#/$defs/tppMessageText"
        }
      }
    },
    "tppMessageCategory": {
      "description": "Category of the TPP message category",
      "type": "string",
      "enum": [
        "INFORMATION",
        "UNMAPPED",
        "ERROR",
        "WARNING"
      ]
    },
    "tppMessageText": {
      "description": "Additional explaining text to the TPP.",
      "type": "string",
      "maxLength": 512
    }
  }
}