<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <xs:element name="IMPOSTconfirmation" type="IMPOSTconfirmationType">
    <xs:annotation>
      <xs:documentation>Version 001 - Release 002</xs:documentation>
    </xs:annotation>
  </xs:element>
  <xs:simpleType name="an..10">
    <xs:restriction base="xs:string">
      <xs:maxLength value="10"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="an..100">
    <xs:restriction base="xs:string">
      <xs:maxLength value="100"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="an..17">
    <xs:restriction base="xs:string">
      <xs:maxLength value="17"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="an..21">
    <xs:restriction base="xs:string">
      <xs:maxLength value="21"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="an..22">
    <xs:restriction base="xs:string">
      <xs:maxLength value="22"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="an..3">
    <xs:restriction base="xs:string">
      <xs:maxLength value="3"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="an..35">
    <xs:restriction base="xs:string">
      <xs:maxLength value="35"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="an..44">
    <xs:restriction base="xs:string">
      <xs:maxLength value="44"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="an..70">
    <xs:restriction base="xs:string">
      <xs:maxLength value="70"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:complexType name="ApplicationInternalDataAdditionalDetailsDataType">
    <xs:sequence>
      <xs:element name="Key" type="an..35" minOccurs="0"/>
      <xs:element name="Value" type="an..100" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="ApplicationInternalDataAdditionalDetailsType">
    <xs:sequence>
      <xs:element name="Data" type="ApplicationInternalDataAdditionalDetailsDataType" minOccurs="0" maxOccurs="999"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="ApplicationInternalDataType">
    <xs:sequence>
      <xs:element name="AdditionalDetails" type="ApplicationInternalDataAdditionalDetailsType" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="IMPOSTconfirmationDataType">
    <xs:sequence>
      <xs:element name="ObjektIdentifizierung" type="IMPOSTconfirmationObjektIdentifizierungType" minOccurs="0"/>
      <xs:element name="Header" type="IMPOSTconfirmationHeaderType" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="IMPOSTconfirmationHeaderType">
    <xs:sequence>
      <xs:element name="PreviousAdministrativeReferences" type="IMPOSTconfirmationPreviousAdministrativeReferencesType" minOccurs="0"/>
      <xs:element name="SummaryDeclaration" type="IMPOSTconfirmationSummaryDeclarationType" minOccurs="0"/>
      <xs:element name="ApplicationInternalData" type="ApplicationInternalDataType" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="IMPOSTconfirmationObjektIdentifizierungType">
    <xs:sequence>
      <xs:element name="ObjektName" type="an..22"/>
      <xs:element name="ObjektAktion" type="an..10" minOccurs="0" maxOccurs="10"/>
      <xs:element name="CompliancePruefung" type="an..3" minOccurs="0"/>
      <xs:element name="Bearbeiter" type="an..70" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="IMPOSTconfirmationPreviousAdministrativeReferencesType">
    <xs:sequence>
      <xs:element name="PreviousAdministrativeReferencesType" type="an..3" minOccurs="0"/>
      <xs:element name="PreviousAdministrativeReferenceNumber" type="an..35" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="IMPOSTconfirmationSummaryDeclarationGoodsItemIdentificationByKeyType">
    <xs:sequence>
      <xs:element name="IdentificationByKeyKind" type="an..3" minOccurs="0"/>
      <xs:element name="IdentificationByKeyNumber" type="an..44" minOccurs="0"/>
      <xs:element name="IdentificationByKeyCustodianEORI" type="an..17" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="IMPOSTconfirmationSummaryDeclarationGoodsItemIdentificationByRegistrationType">
    <xs:sequence>
      <xs:element name="IdentificationByRegistrationNumber" type="an..21" minOccurs="0"/>
      <xs:element name="IdentificationByRegistrationSeq" type="n..4" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="IMPOSTconfirmationSummaryDeclarationGoodsItemType">
    <xs:sequence>
      <xs:element name="SummaryDeclarationQuantity" type="n..5" minOccurs="0"/>
      <xs:element name="IdentificationByKey" type="IMPOSTconfirmationSummaryDeclarationGoodsItemIdentificationByKeyType" minOccurs="0"/>
      <xs:element name="IdentificationByRegistration" type="IMPOSTconfirmationSummaryDeclarationGoodsItemIdentificationByRegistrationType" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="IMPOSTconfirmationSummaryDeclarationType">
    <xs:sequence>
      <xs:element name="SummaryDeclarationIdentification" type="an..3" minOccurs="0"/>
      <xs:element name="SummaryDeclarationGoodsItem" type="IMPOSTconfirmationSummaryDeclarationGoodsItemType" minOccurs="0" maxOccurs="999"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="IMPOSTconfirmationTransactionType">
    <xs:sequence>
      <xs:element name="IOPartner" type="an..100"/>
      <xs:element name="IODivision1" type="an..10" minOccurs="0"/>
      <xs:element name="IODivision2" type="an..10" minOccurs="0"/>
      <xs:element name="IODivision3" type="an..10" minOccurs="0"/>
      <xs:element name="IOReferenz" type="an..35"/>
      <xs:element name="IODatumZeit" type="xs:dateTime"/>
      <xs:element name="Version" type="n3" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="IMPOSTconfirmationType">
    <xs:sequence>
      <xs:element name="Transaktion" type="IMPOSTconfirmationTransactionType" minOccurs="0"/>
      <xs:element name="DeclarationData" type="IMPOSTconfirmationDataType" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>
  <xs:simpleType name="n..4">
    <xs:restriction base="xs:string">
      <xs:maxLength value="100"/>
      <xs:pattern value="( *)(0*)\d{0,4}([.,](0*))?( *)"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="n..5">
    <xs:restriction base="xs:string">
      <xs:maxLength value="100"/>
      <xs:pattern value="( *)(0*)\d{0,5}([.,](0*))?( *)"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="n3">
    <xs:restriction base="xs:nonNegativeInteger">
      <xs:pattern value="\d{3}"/>
      <xs:totalDigits value="3"/>
    </xs:restriction>
  </xs:simpleType>
</xs:schema>
