Payment requests — system description

Data model of the pain.013 payment request basket, conditions for adding items, batching and filing in the document centre, and the permission keys.

Overview

Payment request (ISO 20022 pain.013) for customer invoices — the mirror of the payment order: the client is the beneficiary, the customer the payer; no money moves without the customer's approval. An item is added to the basket with a row action of the Invoices list, and the selected items produce one XML per client in the document centre.

Data model

Table names carry the installation's own prefix in the database.

TablePurposeMain fields
payment_request_itembasket itemclient, partner, invoice, amount, due date, instant, payer IBAN, credited account, status
payment_requestgenerated batch headerclosed items reference it
docthe file in the document centreobject type payment_request

Process

  1. Adding from the invoice: amount is the outstanding amount, credited account the client's default account in the currency, payer IBAN from the document or the partner's default account, due date the invoice due date, instant = 1.
  2. Per-row editing; due date in bulk from the invoice or a fixed date.
  3. Generation: batch = client + credited account + currency (the due date may differ per item); a unique batch reference with an R marker; XML built by the giro engine; filed in the document centre by the client's storage rule (document, otherwise invoice); batch header written and items closed. No transaction is created.
  4. Delete: the selected open items are deleted.

Rules and validation

  • Customer invoices only; open amount greater than 0.5; one open request per invoice.
  • Credited account and payer IBAN are required; a missing one is reported with the partner's name.
  • On generation the credited account needs an IBAN and a storage rule must exist.

Permissions

  • Layer 1: generation also requires modify permission.
  • Layer 2: list, edit (add, save, due date), export, delete, debug.
  • Layer 3: the list and every operation are limited to the user's permitted companies.