XML Schema description

BillJournal

  <xs:element name="BillJournal">
    <xs:complexType>
      <xs:sequence>
        <xs:element name="BillJournalInfo" minOccurs="1" maxOccurs="unbounded">
          <xs:annotation>
            <xs:documentation>Contains events affecting an invoice.</xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:sequence>
              <xs:element name="InvoiceNo" type="InvoiceIdentifier15" minOccurs="1" maxOccurs="1" nillable="false">
                <xs:annotation>
                  <xs:documentation>InvoiceNo is your unique invoice identifier in the accounts receivable.</xs:documentation>
                </xs:annotation>
              </xs:element>
              <xs:element name="CustomerNo" type="Identifier15" minOccurs="1" maxOccurs="1" nillable="false">
                <xs:annotation>
                  <xs:documentation>CustomerNo is your unique identifier of the customer in the accounts receivable.</xs:documentation>
                </xs:annotation>
              </xs:element>
              <xs:element name="InvoiceClaimEvents" minOccurs="0" maxOccurs="1">
                <xs:annotation>
                  <xs:documentation>Containing claim events on an invoice.</xs:documentation>
                </xs:annotation>
                <xs:complexType>
                  <xs:sequence>
                    <xs:element name="InvoiceClaimEvent" type="InvoiceClaimEvent" minOccurs="1" maxOccurs="unbounded">
                      <xs:annotation>
                        <xs:documentation>Contains an invoice claim event.</xs:documentation>
                      </xs:annotation>
                    </xs:element>
                  </xs:sequence>
                </xs:complexType>
              </xs:element>
              <xs:element name="InvoiceStatusEvents" minOccurs="0" maxOccurs="1">
                <xs:annotation>
                  <xs:documentation>Containing status events on an invoice.</xs:documentation>
                </xs:annotation>
                <xs:complexType>
                  <xs:sequence>
                    <xs:element name="InvoiceStatusEvent" type="InvoiceStatusEvent" minOccurs="1" maxOccurs="unbounded">
                      <xs:annotation>
                        <xs:documentation>Contains an invoice status event.</xs:documentation>
                      </xs:annotation>
                    </xs:element>
                  </xs:sequence>
                </xs:complexType>
              </xs:element>
              <xs:element name="InvoiceClaimProcessPauseEvents" minOccurs="0" maxOccurs="1">
                <xs:annotation>
                  <xs:documentation>Containing claim process pause events on an invoice.</xs:documentation>
                </xs:annotation>
                <xs:complexType>
                  <xs:sequence>
                    <xs:element name="InvoiceClaimProcessPauseEvent" type="InvoiceClaimProcessPauseEvent" minOccurs="1" maxOccurs="unbounded">
                      <xs:annotation>
                        <xs:documentation>Contains an invoice claim process pause event</xs:documentation>
                      </xs:annotation>
                    </xs:element>
                  </xs:sequence>
                </xs:complexType>
              </xs:element>
              <xs:element name="InvoiceComplaintEvents" minOccurs="0" maxOccurs="1">
                <xs:annotation>
                  <xs:documentation>Containing complaint events on an invoice.</xs:documentation>
                </xs:annotation>
                <xs:complexType>
                  <xs:sequence>
                    <xs:element name="InvoiceComplaintEvent" type="InvoiceComplaintEvent" minOccurs="1" maxOccurs="unbounded">
                      <xs:annotation>
                        <xs:documentation>Contains an invoice complaint event</xs:documentation>
                      </xs:annotation>
                    </xs:element>
                  </xs:sequence>
                </xs:complexType>
              </xs:element>
              <xs:element name="InvoiceNotificationEvents" minOccurs="0" maxOccurs="1">
                <xs:annotation>
                  <xs:documentation>Containing Notification events on an invoice.</xs:documentation>
                </xs:annotation>
                <xs:complexType>
                  <xs:sequence>
                    <xs:element name="InvoiceNotificationEvent" type="InvoiceNotificationEvent" minOccurs="1" maxOccurs="unbounded">
                      <xs:annotation>
                        <xs:documentation>Contains an invoice claim event.</xs:documentation>
                      </xs:annotation>
                    </xs:element>
                  </xs:sequence>
                </xs:complexType>
              </xs:element>
              <xs:element name="PaymentOrderEvents" minOccurs="0" maxOccurs="1">
                <xs:annotation>
                  <xs:documentation>Containing Payment Order events on an invoice.</xs:documentation>
                </xs:annotation>
                <xs:complexType>
                  <xs:sequence>
                    <xs:element name="PaymentOrderEvent" type="PaymentOrderEvent" minOccurs="1" maxOccurs="unbounded">
                      <xs:annotation>
                        <xs:documentation>Contains an invoice claim event.</xs:documentation>
                      </xs:annotation>
                    </xs:element>
                  </xs:sequence>
                </xs:complexType>
              </xs:element>
            </xs:sequence>
          </xs:complexType>
        </xs:element>
      </xs:sequence>
      <xs:attribute name="Version" type="Version" use="required">
        <xs:annotation>
          <xs:documentation>Versions supported by this schema</xs:documentation>
        </xs:annotation>
      </xs:attribute>
      <xs:attribute name="CreatedDateTime" type="xs:dateTime" use="required">
        <xs:annotation>
          <xs:documentation>The date and time when the file was created</xs:documentation>
        </xs:annotation>
      </xs:attribute>
      <xs:attribute name="CompanyNo" type="CompanyNumber" use="required">
        <xs:annotation>
          <xs:documentation>Your accounts receivable number at PayEx</xs:documentation>
        </xs:annotation>
      </xs:attribute>
      <xs:attribute name="CompanyName" type="xs:string" use="required">
        <xs:annotation>
          <xs:documentation>The name of your company/accounts recievable at PayEx</xs:documentation>
        </xs:annotation>
      </xs:attribute>
    </xs:complexType>
  </xs:element>

Identifier15

  <xs:simpleType name="Identifier15">
    <xs:restriction base="xs:string">
      <xs:pattern value="[a-zA-Z0-9äåöÄÅÖ&/_ -.]*"/>
      <xs:minLength value="1"/>
      <xs:maxLength value="15"/>
    </xs:restriction>
  </xs:simpleType>

ISO3166

  <xs:simpleType name="ISO3166">
    <xs:restriction base="xs:string">
      <xs:pattern value="[A-Z]*"/>
      <xs:minLength value="2"/>
      <xs:maxLength value="2"/>
    </xs:restriction>
  </xs:simpleType>

CompanyNumber

  <xs:simpleType name="CompanyNumber">
    <xs:restriction base="xs:string">
      <xs:pattern value="[0-9]*"/>
      <xs:minLength value="1"/>
      <xs:maxLength value="15"/>
    </xs:restriction>
  </xs:simpleType>

ISO639

  <xs:simpleType name="ISO639">
    <xs:restriction base="PXString">
      <xs:enumeration value="SV"/>
      <xs:enumeration value="NO"/>
      <xs:enumeration value="DA"/>
      <xs:enumeration value="FI"/>
      <xs:enumeration value="EN"/>
    </xs:restriction>
  </xs:simpleType>

String35

  <xs:simpleType name="String35">
    <xs:restriction base="PXString">
      <xs:maxLength
           value="35"/>
    </xs:restriction>
  </xs:simpleType>

Email

  <xs:simpleType name="Email">
    <xs:restriction base="PXString">
      <xs:maxLength
           value="60"/>
    </xs:restriction>
  </xs:simpleType>

String15

  <xs:simpleType name="String15">
    <xs:restriction base="PXString">
      <xs:maxLength value="15"/>
    </xs:restriction>
  </xs:simpleType>

ZipCode

  <xs:simpleType name="ZipCode">
    <xs:restriction base="xs:string">
      <xs:pattern value="[A-Z0-9\-]+"/>
      <xs:maxLength value="9"/>
    </xs:restriction>
  </xs:simpleType>

VatNumber

  <xs:simpleType name="VatNumber">
    <xs:restriction base="xs:string">
      <xs:pattern value="[A-Z]{2}.*"/>
      <xs:minLength value="7"/>
      <xs:maxLength value="14"/>
    </xs:restriction>
  </xs:simpleType>

String50

  <xs:simpleType name="String50">
    <xs:restriction base="xs:string">
      <xs:maxLength
           value="50"/>
    </xs:restriction>
  </xs:simpleType>

InvoiceClaimEvent

  <xs:complexType name="InvoiceClaimEvent">
    <xs:sequence>
      <xs:element name="ClaimEvent" type="eClaimEvent" minOccurs="1" maxOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>Type of claim event from enumeration.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ClaimEventDate" type="xs:date" minOccurs="1" maxOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>The date when the event occurred.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="BillAmount" type="BillAmount" maxOccurs="1" minOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>The claim amount at the time of the claimevent.</xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
  </xs:complexType>

InvoiceStatusEvent

  <xs:complexType name="InvoiceStatusEvent">
    <xs:sequence>
      <xs:element name="InvoiceStatus" type="eInvoiceStatus" minOccurs="1" maxOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>Type of status event from enumeration.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="InvoiceSubStatus" type="eInvoiceSubStatus" minOccurs="0" maxOccurs="1">
        <xs:annotation>
          <xs:documentation>Used to clarify why the InvoiceStatus is set. Reasons is listed in the enumeration eInvoiceSubStatus.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="StatusEventDate" type="xs:date" minOccurs="1" maxOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>The date when the event occurred</xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
  </xs:complexType>

InvoiceClaimProcessPauseEvent

  <xs:complexType name="InvoiceClaimProcessPauseEvent">
    <xs:sequence>
      <xs:element name="ClaimProcessPauseEvent" type="eClaimProcessPauseEventType" minOccurs="1" maxOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>Type of claim process pause event from enumeration.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ClaimProcessPauseEventDate" type="xs:date" minOccurs="1" maxOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>The date when the event occurred</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ValidToDate" type="xs:date" minOccurs="0" maxOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>If exists, the date to which the claim process pause is valid to.</xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
  </xs:complexType>

InvoiceComplaintEvent

  <xs:complexType name="InvoiceComplaintEvent">
    <xs:sequence>
      <xs:element name="ComplaintStatus" type="eComplaintStatus" minOccurs="1" maxOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>Type of complaint status from enumeration.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ComplaintEventDate" type="xs:date" minOccurs="1" maxOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>The date when the event occurred</xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
  </xs:complexType>

InvoiceNotificationEvent

  <xs:complexType name="InvoiceNotificationEvent">
    <xs:sequence>
      <xs:element name="NotificationType" type="eNotificationType" minOccurs="1" maxOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>Type of Notification event from enumeration.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="NotificationEventDate" type="xs:date" minOccurs="1" maxOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>The date when the event occurred.</xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
  </xs:complexType>

PaymentOrderEvent

  <xs:complexType name="PaymentOrderEvent">
    <xs:sequence>
      <xs:element name="PaymentOrderStatusCode" type="ePaymentOrderStatus" minOccurs="1" maxOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>Payment order status from enumeration.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="PaymentOrderEventDate" type="xs:date" minOccurs="1" maxOccurs="1" nillable="false">
        <xs:annotation>
          <xs:documentation>The date when the event occurred.</xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
  </xs:complexType>

BillAmount

  <xs:complexType name="BillAmount">
    <xs:sequence>
      <xs:element name="AmountInclVat" type="Money" minOccurs="1" maxOccurs="1" nillable="false"/>
    </xs:sequence>
    <xs:attribute name="Currency" type="eCurrencyType" use="required"/>
  </xs:complexType>

eClaimProcessPauseEventType

  <xs:simpleType name="eClaimProcessPauseEventType">
    <xs:restriction base="xs:string">
      <xs:enumeration value="Stop">
        <xs:annotation>
          <xs:documentation>The claim is stopped for further claim process steps until stop is removed.</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="Respite">
        <xs:annotation>
          <xs:documentation>The claim is stopped for further claimprocess steps until valid to data of respite or respite is removed.</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="StopRemoved">
        <xs:annotation>
          <xs:documentation>Stop has been removed from claim.</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="RespiteRemoved">
        <xs:annotation>
          <xs:documentation>Respite has been removed fro claim</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
    </xs:restriction>
  </xs:simpleType>

eComplaintStatus

  <xs:simpleType name="eComplaintStatus">
    <xs:restriction base="xs:string">
      <xs:enumeration value="ComplaintReceived">
        <xs:annotation>
          <xs:documentation>Complaint has been registered</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="ComplaintResolved">
        <xs:annotation>
          <xs:documentation>Complaint has been resolved</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
    </xs:restriction>
  </xs:simpleType>

eInvoiceStatus

  <xs:simpleType name="eInvoiceStatus">
    <xs:restriction base="xs:string">
      <xs:enumeration value="Closed">
        <xs:annotation>
          <xs:documentation>Status of the invoice in the accounts receivable has been set to closed</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="Rest">
        <xs:annotation>
          <xs:documentation>Status of the invoice in the accounts receivable has been set to rest, meaning that remaing amount to settle is below or egual to configured amount.</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
    </xs:restriction>
  </xs:simpleType>

eClaimEvent

  <xs:simpleType name="eClaimEvent">
    <xs:restriction base="xs:string">
      <xs:enumeration value="ReminderSent">
        <xs:annotation>
          <xs:documentation>An invoice reminder has been sent to the customer</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="SecondReminderSent">
        <xs:annotation>
          <xs:documentation>A second invoice reminder has been sent to the customer</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="CollectionClaimSent">
        <xs:annotation>
          <xs:documentation>A collection claim has been sent to the customer</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="RestReminderSent">
        <xs:annotation>
          <xs:documentation>A reminder including only interest and fees has been sent to the customer</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="DebtCollection">
        <xs:annotation>
          <xs:documentation>The invoice has been transferred to collection</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
    </xs:restriction>
  </xs:simpleType>

eNotificationType

  <xs:simpleType name="eNotificationType">
    <xs:restriction base="xs:string">
      <xs:enumeration value="PreDueDate">
        <xs:annotation>
          <xs:documentation>Notification before the invoice due date</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="PreReminder">
        <xs:annotation>
          <xs:documentation>Notification before the reminder is sent</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="PreCollectionClaim">
        <xs:annotation>
          <xs:documentation>Notification before the collection claim is sent</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
    </xs:restriction>
  </xs:simpleType>

ePaymentOrderStatus

  <xs:simpleType name="ePaymentOrderStatus">
    <xs:restriction base="xs:string">
      <xs:enumeration value="WillRetry">
        <xs:annotation>
          <xs:documentation>Retries will be made</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="InsufficientFunds">
        <xs:annotation>
          <xs:documentation>Insufficient funds in the account</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
    </xs:restriction>
  </xs:simpleType>

eCurrencyType

  <xs:simpleType name="eCurrencyType">
    <xs:restriction base="xs:string">
      <xs:enumeration value="SEK"/>
      <xs:enumeration value="NOK"/>
      <xs:enumeration value="DKK"/>
      <xs:enumeration value="EUR"/>
    </xs:restriction>
  </xs:simpleType>

eInvoiceSubStatus

  <xs:simpleType name="eInvoiceSubStatus">
    <xs:restriction base="xs:string">
      <xs:enumeration value="Sold">
        <xs:annotation>
          <xs:documentation>The invoice has been sold to another part</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="Loss">
        <xs:annotation>
          <xs:documentation>Indicates that the invoice has been credited with loss</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="Converted">
        <xs:annotation>
          <xs:documentation>The invoice has been converted to a credit account</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="Diff">
        <xs:annotation>
          <xs:documentation>The invoice has been closed after having been listed (status Rest) for a certain time</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
      <xs:enumeration value="Reversal">
        <xs:annotation>
          <xs:documentation>The invoice has been fully credited or a chargeback has been made</xs:documentation>
        </xs:annotation>
      </xs:enumeration>
    </xs:restriction>
  </xs:simpleType>

Version

  <xs:simpleType name="Version">
    <xs:restriction base="xs:string">
      <xs:enumeration value="1.0"/>
      <xs:enumeration value="1.1"/>
      <xs:enumeration value="1.2"/>
    </xs:restriction>
  </xs:simpleType>

Money

  <xs:simpleType name="Money">
    <xs:restriction base="xs:decimal">
      <xs:fractionDigits value="2"/>
      <xs:minInclusive value="-100000000"/>
      <xs:maxInclusive
           value="100000000"/>
    </xs:restriction>
  </xs:simpleType>

String10

  <xs:simpleType name="String10">
    <xs:restriction base="PXString">
      <xs:maxLength value="10"/>
    </xs:restriction>
  </xs:simpleType>

String30

  <xs:simpleType name="String30">
    <xs:restriction base="PXString">
      <xs:maxLength
           value="30"/>
    </xs:restriction>
  </xs:simpleType>

String25

  <xs:simpleType name="String25">
    <xs:restriction base="PXString">
      <xs:maxLength
           value="25"/>
    </xs:restriction>
  </xs:simpleType>

InvoiceIdentifier15

  <xs:simpleType name="InvoiceIdentifier15">
    <xs:restriction base="xs:string">
      <xs:pattern value="[A-Za-z0-9\-]+"/>
      <xs:maxLength value="15"/>
    </xs:restriction>
  </xs:simpleType>

PXString

  <xs:simpleType name="PXString">
    <xs:restriction base="xs:string">
      <xs:pattern value="[a-zA-Z0-9_:!;"#<>=?\[\]@{}´

 %-/À-ÖØ-öø-ú]*"/>
      <xs:minLength value="1"/>
    </xs:restriction>
  </xs:simpleType>

Created by David Persson on 2019/06/20 08:45