<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns="http://www.mf.gov.pl/schematy/SZPROT/e-Klient/WREX001/1.0.xsd" xmlns:sz="http://www.mf.gov.pl/schematy/SZPROT/Typy/1.0.xsd" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" targetNamespace="http://www.mf.gov.pl/schematy/SZPROT/e-Klient/WREX001/1.0.xsd" elementFormDefault="qualified" attributeFormDefault="unqualified">
  <xs:import namespace="http://www.mf.gov.pl/schematy/SZPROT/Typy/1.0.xsd" schemaLocation="http://seap-intranet-ws:8080/seap_schematy/xsd?id=1021325"/>
  <xs:import namespace="http://www.w3.org/2000/09/xmldsig#" schemaLocation="http://seap-intranet-ws:8080/seap_schematy/xsd?id=10125"/>
  <xs:element name="WREX001">
    <xs:annotation>
      <xs:documentation source="rootName" xml:lang="pl">
        WREX001
      </xs:documentation>
      <xs:documentation source="rootDoc" xml:lang="pl">
        Wniosek o nadanie statusu zarejestrowanego eksportera.
      </xs:documentation>
      <xs:documentation source="rootDoc" xml:lang="pl">
        Komunikat jest przekazywany przez podmiot do SZPROT PLUS.
      </xs:documentation>
      <xs:documentation source="doc" xml:lang="pl">
        Element główny.
      </xs:documentation>
    </xs:annotation>
    <xs:complexType>
      <xs:sequence>
        <xs:element name="Naglowek">
          <xs:annotation>
            <xs:documentation source="name" xml:lang="pl">
              Nagłówek
            </xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:complexContent>
              <xs:extension base="sz:NaglowekType">
                <xs:attribute name="rexOperacjaKod" use="required">
                  <xs:annotation>
                    <xs:documentation source="name" xml:lang="pl">
                      Kod operacji REX
                    </xs:documentation>
                    <xs:documentation source="doc" xml:lang="pl">
                      Kod operacji w systemie REX (cel złożenia wniosku). Możliwe wartości: "1" (Rejestracja), "2" (Aktualizacja), "3" (Dezaktywacja).
                    </xs:documentation>
                    <xs:documentation source="rule">
                      R115
                    </xs:documentation>
                  </xs:annotation>
                  <xs:simpleType>
                    <xs:restriction base="xs:string">
                      <xs:length value="1"/>
                      <xs:enumeration value="1"/>
                      <xs:enumeration value="2"/>
                      <xs:enumeration value="3"/>
                    </xs:restriction>
                  </xs:simpleType>
                </xs:attribute>
              </xs:extension>
            </xs:complexContent>
          </xs:complexType>
        </xs:element>
        <xs:element name="Podmiot">
          <xs:annotation>
            <xs:documentation source="name" xml:lang="pl">
              Podmiot
            </xs:documentation>
            <xs:documentation source="doc" xml:lang="pl">
              Dane identyfikacyjne podmiotu
            </xs:documentation>
            <xs:documentation source="rule">
              R97
            </xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:complexContent>
              <xs:extension base="sz:PodmiotIdentyfikacjaType">
                <xs:attribute name="nrRex" use="optional">
                  <xs:annotation>
                    <xs:documentation source="name" xml:lang="pl">
                      Numer REX
                    </xs:documentation>
                    <xs:documentation source="rule">
                      R90
                    </xs:documentation>
                  </xs:annotation>
                  <xs:simpleType>
                    <xs:restriction base="xs:string">
                      <xs:maxLength value="35"/>
                    </xs:restriction>
                  </xs:simpleType>
                </xs:attribute>
                <xs:attribute name="dzialalnoscGlownaKod" use="required">
                  <xs:annotation>
                    <xs:documentation source="name" xml:lang="pl">
                      Kod określający rodzaj działalności głównej Wnioskodawcy
                    </xs:documentation>
                    <xs:documentation source="list">
                      1627
                    </xs:documentation>
                  </xs:annotation>
                  <xs:simpleType>
                    <xs:restriction base="xs:string">
                      <xs:length value="1"/>
                    </xs:restriction>
                  </xs:simpleType>
                </xs:attribute>
                <xs:attribute name="dzialalnoscGlownaNazwa" use="optional">
                  <xs:annotation>
                    <xs:documentation source="nazwa">
                      Nazwa działalności głównej.
                    </xs:documentation>
                    <xs:documentation source="doc">
                      Opis do kodu działalności głównej.
                    </xs:documentation>
                  </xs:annotation>
                  <xs:simpleType>
                    <xs:restriction base="xs:string">
                      <xs:maxLength value="140"/>
                    </xs:restriction>
                  </xs:simpleType>
                </xs:attribute>
              </xs:extension>
            </xs:complexContent>
          </xs:complexType>
        </xs:element>
        <xs:element name="Adres" type="sz:AdresType">
          <xs:annotation>
            <xs:documentation source="name" xml:lang="en">
              Adres
            </xs:documentation>
            <xs:documentation source="rule">
              R102
            </xs:documentation>
          </xs:annotation>
        </xs:element>
        <xs:element name="DedykowanyKontakt" maxOccurs="9">
          <xs:annotation>
            <xs:documentation source="name" xml:lang="pl">
              Dane osoby do kontaktu w sprawie REX
            </xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:attribute name="zastosowanieNazwa" use="optional">
              <xs:annotation>
                <xs:documentation source="name" xml:lang="pl">
                  Zastosowanie
                </xs:documentation>
              </xs:annotation>
              <xs:simpleType>
                <xs:restriction base="xs:string">
                  <xs:maxLength value="70"/>
                </xs:restriction>
              </xs:simpleType>
            </xs:attribute>
            <xs:attribute name="imie" use="required">
              <xs:annotation>
                <xs:documentation source="name" xml:lang="pl">
                  Imię
                </xs:documentation>
                <xs:documentation source="doc" xml:lang="pl">
                  Imię osoby do kontaktu
                </xs:documentation>
              </xs:annotation>
              <xs:simpleType>
                <xs:restriction base="xs:string">
                  <xs:maxLength value="60"/>
                </xs:restriction>
              </xs:simpleType>
            </xs:attribute>
            <xs:attribute name="nazwisko" use="required">
              <xs:annotation>
                <xs:documentation source="name" xml:lang="pl">
                  Nazwisko
                </xs:documentation>
                <xs:documentation source="doc">
                  Nazwisko osoby do kontaktu
                </xs:documentation>
              </xs:annotation>
              <xs:simpleType>
                <xs:restriction base="xs:string">
                  <xs:maxLength value="90"/>
                </xs:restriction>
              </xs:simpleType>
            </xs:attribute>
            <xs:attribute name="telefon" use="optional">
              <xs:annotation>
                <xs:documentation source="name" xml:lang="pl">
                  Numer telefonu
                </xs:documentation>
                <xs:documentation source="rule">
                  R24
                </xs:documentation>
              </xs:annotation>
              <xs:simpleType>
                <xs:restriction base="xs:string">
                  <xs:maxLength value="50"/>
                </xs:restriction>
              </xs:simpleType>
            </xs:attribute>
            <xs:attribute name="email" use="optional">
              <xs:annotation>
                <xs:documentation source="name" xml:lang="pl">
                  Email
                </xs:documentation>
                <xs:documentation source="rule">
                  R24
                </xs:documentation>
              </xs:annotation>
              <xs:simpleType>
                <xs:restriction base="xs:string">
                  <xs:maxLength value="50"/>
                </xs:restriction>
              </xs:simpleType>
            </xs:attribute>
          </xs:complexType>
        </xs:element>
        <xs:element name="Towar" minOccurs="0" maxOccurs="99">
          <xs:annotation>
            <xs:documentation source="name" xml:lang="pl">
              Informacja o towarach
            </xs:documentation>
            <xs:documentation source="doc" xml:lang="pl">
              Numer pozycji lub dział taryfy celnej dla towarów , które kwalifikują się do preferencyjnego traktowania
            </xs:documentation>
            <xs:documentation source="rule">
              R115
            </xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:attribute name="kod" use="required">
              <xs:annotation>
                <xs:documentation source="name" xml:lang="pl">
                  Kod pozycji lub działu taryfy celnej
                </xs:documentation>
                <xs:documentation source="rule">
                  R70, R71, R72, R73
                </xs:documentation>
                <xs:documentation source="list">
                  028
                </xs:documentation>
              </xs:annotation>
              <xs:simpleType>
                <xs:restriction base="xs:string">
                  <xs:maxLength value="4"/>
                </xs:restriction>
              </xs:simpleType>
            </xs:attribute>
          </xs:complexType>
        </xs:element>
        <xs:element name="Oswiadczenie" type="sz:OswiadczenieType" maxOccurs="99">
          <xs:annotation>
            <xs:documentation source="name" xml:lang="pl">
              Oświadczenie
            </xs:documentation>
            <xs:documentation source="rule">
              R69
            </xs:documentation>
          </xs:annotation>
        </xs:element>
        <xs:element name="Zalacznik" type="sz:PlikType" minOccurs="0" maxOccurs="9">
          <xs:annotation>
            <xs:documentation source="name" xml:lang="pl">
              Załącznik
            </xs:documentation>
          </xs:annotation>
        </xs:element>
        <xs:element name="Wnioskodawca">
          <xs:annotation>
            <xs:documentation source="name" xml:lang="pl">
              Wnioskodawca
            </xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:complexContent>
              <xs:extension base="sz:WnioskodawcaType"/>
            </xs:complexContent>
          </xs:complexType>
        </xs:element>
        <xs:element ref="ds:Signature" minOccurs="0"/>
      </xs:sequence>
    </xs:complexType>
  </xs:element>
</xs:schema>