Systems and records
Paid on time, off terms: building a payment terms compliance dataset
By SourceX Editorial · Reviewed by Noah Loul ·
9 sections
Short answer
A payment terms compliance dataset should grade each payment against every term in force on the day it was made, not only the due date. Store a dated terms snapshot, then give date, discount window, amount tolerance, currency, method, charges and payee their own verdicts. Timing-only measures miss the rest: UK reporting counts payments made outside agreed periods, and LedgerSMB reads discount terms from the supplier's current settings.
License terms
Paid on time, off terms
Key takeaways
- Grade each term separately: a payment can meet the due date and still break the discount, currency, method, charges or payee terms.
- Snapshot the terms that governed on the payment date; LedgerSMB stores days to pay and a due date on each bill but reads discount terms from the counterparty's current settings.
- One LedgerSMB code base codes the last day of a discount window three ways, so record the day-count rule with every case, not just the dates.
- Federal prompt-payment rules show early and discounted payments have rules too: no discount after the discount date, and payment generally no more than seven days early.
- UK payment practices reports count late payments, their value and the disputed share; nothing in them tests amount, currency or method.
What should a payment terms compliance dataset grade besides the due date?
Every condition the parties agreed for how the money moves: when, how much, in what currency, by what means, net of whose bank charges, to which account and with which reference. Arriving by the due date is one verdict among eight, and a payment can pass it while failing others, for example by deducting an early-payment discount after the discount window has closed.
At a glance
What should a payment terms compliance dataset grade besides the due date
Labels built from payment dates alone miss those failures, and so do most public measures of payment behavior. Who was allowed to approve the payment is a separate question, covered on the treasury payment approval page. The eight terms, each graded on its own:
- Due date: paid on or before the date the terms set, under a stated rule for weekends and holidays.
- Earliest date: not paid sooner than a contract or policy allows, where such a limit exists.
- Discount: any early-payment discount taken only inside its window and computed on the base the terms name.
- Amount: the amount paid falls within the tolerance in force for that supplier, after deductions the terms allow.
- Currency: paid in the invoice or contract currency, or converted under an agreed rate rule.
- Method: sent by the agreed means, such as electronic transfer or card, through the agreed channel.
- Charges: bank charges borne by the party the terms name, so the payee receives the agreed amount.
- Payee and reference: sent to the account on file when the payment was released, carrying the reference the terms require.
Which terms governed on the day the money moved?
The terms in force on the day the payment was released, which may differ from what any record shows today. Terms can sit in a contract and its amendments, a purchase order, the invoice and the supplier's master record, and the last two can change without touching old transactions.
LedgerSMB shows how a system can quietly re-date terms. At commit 0cebbd9, its payables and receivables tables store the number of days to pay and a due date on each bill, but no discount fields; the discount percentage and discount days live on the counterparty's credit account. When the payment functions decide whether a discount applies, they read those account settings at payment time and compare them with the invoice's age. Edit the supplier's discount terms, and every open bill is judged by the new ones.
Tolerances behave the same way. Oracle Fusion Payables checks invoice matching variances against the quantity and amount tolerance templates assigned to a supplier, falling back to defaults on its invoice options page, and its guide warns that a percentage tolerance of zero allows no variance while an active tolerance left without a value allows infinite variance. A label that does not store which tolerance applied, and its value that day, cannot be checked later.
What to snapshot for each payment, by where the term lives:
| Term source | Where it usually lives | What changes it | What the packet stores |
|---|---|---|---|
| Contract and amendments | Signed agreement and amendment log | A signed amendment with an effective date | Clause text and the version in force on the payment date |
| Purchase order | Procurement system | Change orders | PO terms at release, with the change history |
| Invoice | Payables record and invoice image | A corrected or reissued invoice | Invoice date, stated terms and any discount offer |
| Supplier master | Vendor or credit account record | Edits by master-data staff | Settings as of the release date, not today's |
| Tolerance and policy | Payables configuration | Configuration changes | The tolerance value and policy version that applied |
| Bank and remittance | Bank statement and remittance advice | Nothing after execution | Value date, currency, charges and reference as executed |
What public payment rules treat as paid on terms
Mostly lateness. The UK's Reporting on Payment Practices and Performance Regulations 2017 ask large companies to report, among other statistics, "the percentage of those payments which were not made within the payment period"; amendments in 2024 added the total value of late payments and the share that were late because of a dispute. Nothing in the return asks whether the amount, currency or method matched the agreement.
US federal prompt-payment rules go further. Under 5 CFR 1315.7, an agency may take a discount only when it is economically justified and only after acceptance, the discount period runs from the date the vendor placed on a proper invoice, payment is to be made "as close as possible to, but no later than, the discount date", and an agency that takes a discount after the deadline must pay an interest penalty on the amount left unpaid. Under 5 CFR 1315.4, a payment due on a weekend or federal holiday may be made the next business day without a late-payment penalty, and payment generally comes no more than seven days before the due date unless an agency determines case by case that earlier payment is necessary. FAR 52.232-8 carries the discount rule into contracts: an offered discount "will be taken if payment is made within the discount period indicated in the offer by the offeror."
Two other rules govern terms beyond timing. For payments where the providers are in the European Union, the payment services directive sets a default in which "the payee pays the charges levied by his payment service provider, and the payer pays the charges levied by his payment service provider", so a contract that puts all charges on one party is a private term layered on that default. Under UCC 2-511, "Tender of payment is sufficient when made by any means or in any manner current in the ordinary course of business unless the seller demands payment in legal tender", and a check is conditional payment, defeated if it is dishonored.
What each rule treats as compliant, and the field a dataset needs to grade it:
| Rule | Applies to | Treated as compliant | Terms beyond the date | Field the dataset needs |
|---|---|---|---|---|
| UK payment practices regulations, 2017, amended 2024 | Large UK companies' reports | Paid within the agreed payment period | None; disputes are counted as a cause of lateness | Agreed period per payment and a dispute flag |
| 5 CFR 1315.7 | US federal agencies taking discounts | Discount taken no later than the discount date, after acceptance | Discount window and its start date | Vendor's invoice date, acceptance date and discount date |
| 5 CFR 1315.4 | US federal agencies paying invoices | Paid by the due date; next business day if it falls on a weekend or holiday | Earliest payment date | Due date rule, holiday calendar, any early-payment determination |
| FAR 52.232-8 | Federal contracts with a discount offer | Discount taken only within the offered period | The offer's discount terms | Offer terms and the payment date used to test them |
| Directive (EU) 2015/2366, Article 62(2) | Payments with providers in the EU | Each party pays its own provider's charges | Allocation of bank charges | Charge code and the amount credited to the payee |
| UCC 2-511 | US sales of goods | Any customary means unless legal tender is demanded; checks are conditional | Method and its finality | Method, clearing date and any dishonor |
Seven timely payments that still broke the agreed terms
Each case below arrives on time and still departs from what was agreed. All are Illustrative, invented to show a pattern; days count from the invoice date and amounts are in plain units. The columns give the terms in force, what was paid, the failed term with its label, and the record that settles it:
| Case (Illustrative) | Terms in force | What was paid | Term failed and label | Record that settles it |
|---|---|---|---|---|
| Discount after the window | 2 percent off within 10 days, net 30 | Day 18, invoice amount less 2 percent | Discount: taken late | Invoice date, payment value date, discount clause |
| Wrong currency | Invoice and contract in euros | Day 25, an equivalent sum in US dollars | Currency: unagreed conversion | Contract currency clause and the bank credit advice |
| Check where a transfer was required | Electronic transfer to the account on file | Day 20, check mailed | Method: off terms | Payment method clause and remittance record |
| Charges taken from the amount | Payer bears all bank charges | Day 28, sent with charges shared | Charges: payee received less than agreed | Charge code on the transfer and the payee's credit advice |
| Paid too early under policy | Policy: no payment more than 7 days before the due date | Day 5 on a 30-day bill, no exception recorded | Earliest date (policy): early without authority | Policy version and any exception approval |
| Discount terms edited mid-cycle | Invoice offered 10 days; supplier record later changed to 15 | Day 13, discount taken | Discount: judged by terms not in force | Invoice image and supplier master history |
| Short by today's tolerance, not that day's | Amount tolerance 1 percent at payment, later raised to 3 | Day 22, 2 percent below the invoice | Amount: outside the tolerance in force | Tolerance configuration history |
The last day of a discount window, coded three ways
Record the day-count rule with every case, because even one code base can disagree about the last day of a discount window. In LedgerSMB at commit 0cebbd9, the function that lists open invoices for a payment withholds the discount only when the discount days are less than the invoice's age, so the discount is still offered on the last day. The routine that posts bulk payments grants it only while the invoice's age is less than the discount days, so on the last day it computes none.
A third test, in the function that gathers each contact's invoices for bulk payment, points the other way for the contact's total due: it withholds the discount while the discount days exceed the invoice's age and subtracts it once the age reaches them, while the per-invoice figures in the same function follow the first rule. We read the SQL and did not run the software, so we cannot say which figure a user sees; for a dataset, the lesson is that "paid within the discount period" has at least three codings in one code base.
Rules need the same precision. The federal discount period starts from the invoice date the vendor placed on a proper invoice, falling back to the date of receipt only when the invoice is undated, and under the federal rule a due date that falls on a weekend or holiday moves to the next business day. A labeler who silently picks a convention will mark the same payment compliant in one batch and off terms in another, so the dataset should fix one convention per term and store it with every case.
Reviewer rubric: one verdict per term, never a blended score
Give each term its own verdict, compliant, off terms or not determinable, and derive the payment label from the set instead of averaging. One off-terms verdict makes the payment off terms whatever the others say; a not-determinable verdict with no failures makes it incomplete, never compliant.
Two qualified reviewers should grade a sample independently, with agreement reported per term. Date and discount checks can be computed once the conventions are fixed; currency, charges and method need the contract text; whether a departure was authorized needs the approval record.
The rubric, term by term:
| Term | Compliant when | Off terms when | Not determinable when | Scored by |
|---|---|---|---|---|
| Due and earliest date | Value date inside the window under the stated day-count and holiday rule | After the due date, or before an early limit with no exception | No terms snapshot or no value date | Computed, with the convention fixed per dataset |
| Discount | Taken inside the window on the named base, or not taken | Taken after the window or on the wrong base | Discount terms on the invoice date unknown | Computed; reviewer confirms the base |
| Amount | Within the tolerance in force, after allowed deductions | Outside it, or a deduction the terms do not allow | Tolerance history missing | Computed; accountant reviews deductions |
| Currency and charges | Agreed currency, charges borne as agreed | Converted without an agreed rate rule, or charges shifted to the payee | Bank credit advice missing | Accountant with the contract text |
| Method and channel | Agreed means and channel, and the payment cleared | Other means with no recorded waiver, or dishonored | Method field blank | Reviewer with the remittance record |
| Payee and reference | Account on file at release, required reference present | Different account, or reference missing | Master history unavailable | Reviewer with master-data history |
Is a correct amount paid on time proof of compliance?
No. Arithmetic that matches the invoice shows the numbers agree, not that the payment was allowed to depart from the terms or that the person releasing it could approve the departure. A late discount may have been agreed by email; an early payment may rest on an exception, as the federal rule allows when an agency determines it case by case; a dispute may have suspended the due date.
Each off-terms verdict therefore needs one more field: whether an authorized departure exists, and the record that proves it. Without that field, a model learns to flag every negotiated exception as a breach, the mirror image of the timing-only error. Accounting treatment needs the same care, since a discount taken late may be booked, reversed or billed back depending on policy, and only a qualified accountant can label which was right.
Assembling payment packets from remittance, bank and contract records
One packet per payment: the terms snapshot, the invoice record or image, the remittance advice, the bank entry with value date, currency, charges and reference, the supplier master as of the release date, and the reviewer verdicts with any departure approval. Tokenize account numbers, names and references consistently, so the payee check still works across packets, and keep amounts and dates exact, because rounding erases the boundary cases.
Sample the hard cases on purpose: payments in the last days of a discount window, cross-currency payments, method changes and supplier records edited during the period, each at a stated sampling rate so that results can be reweighted to the full population.
SourceX looks for datasets on request rather than keeping them in stock, and the company holding the records approves scope and terms and signs before anything is delivered. A requirement that names the terms in scope, the snapshot fields and the acceptance test, for example rubric agreement on a sample the buyer grades, is where that search starts; whether a given company's records can meet it is decided case by case.
Methods note: what was read, how, and what was not measured
The LedgerSMB findings come from bin/discount_terms.py, which reads sql/Pg-database.sql and sql/modules/Payment.sql from a shallow clone of ledgersmb/LedgerSMB at commit 0cebbd9, made on October 27, 2026, and runs nothing from the repository. It prints every column whose name contains discount, terms, due, curr or bank in the entity_credit_account, ap and ar tables, and every line of Payment.sql that compares discount_terms with an invoice's age, classified by the direction of the comparison: six comparisons offer the discount on the last day, one refuses it on the last day, and one withholds it inside the window.
The rule texts (the UK regulations and their 2024 amendment, 5 CFR 1315.4 and 1315.7, FAR 52.232-8, the EU payment services directive and UCC 2-511) and Oracle's guide were read through search excerpts from their official publishers on October 27, 2026; a reviewer should open each before release.
Not measured: how often real payments break each term, how often discounts are taken late, and reviewer agreement on the rubric. Those need authorized payment records, and no results are reported here. This is general information, not legal or accounting advice; counsel and a qualified accountant should confirm which rules and terms govern a given payment.
Frequently asked questions
What is a payment terms compliance dataset?
It is a set of executed payments, each paired with the terms in force on the payment date and a separate verdict for every term: due date, earliest date, discount, amount, currency, method, charges and payee. It lets a model learn to check a payment against its agreement, not just against a calendar.
Can a payment be on time and still violate the payment terms?
Yes. A payment can arrive before the due date while deducting a discount after its window closed, arriving in the wrong currency, using a method the contract excludes, or leaving bank charges with the payee. Each is a breach of terms even though the payment was timely.
Why store a terms snapshot instead of the current supplier record?
Because supplier settings change, and some systems apply today's settings to old invoices. LedgerSMB, for example, reads discount terms from the counterparty's account at payment time, so an edit after the invoice changes how the payment would be judged.
How should a dataset treat the last day of a discount window?
Pick one convention, state it and store it with each case. Systems differ: one LedgerSMB function offers the discount on the last day while its bulk posting refuses it, and federal rules count the period from the vendor's invoice date.
Do public payment practice reports measure payment terms compliance?
Only timing. The UK's reporting rules ask for the share of payments not made within the agreed period, plus, since 2024, the value of late payments and the share late because of disputes. Amount, currency and method compliance need payment-level evidence those reports do not collect.
Sources
- The UK's 2017 payment practices regulations require large companies to report the percentage of payments not made within the payment period. Source
- The 2024 amendment adds the total value of late payments and the percentage of payments late because of a dispute. Source
- 5 CFR 1315.7 sets federal discount rules: after acceptance, from the vendor's invoice date, no later than the discount date, with interest if a discount is taken late. Source
- 5 CFR 1315.4 allows next-business-day payment for weekend or holiday due dates and generally limits payment to seven days before the due date. Source
- FAR 52.232-8 says an offered prompt-payment discount will be taken if payment is made within the discount period in the offer. Source
- Directive (EU) 2015/2366 Article 62(2) makes each party pay its own payment service provider's charges for payments within the Union. Source
- UCC 2-511 treats tender by any customary means as sufficient unless legal tender is demanded, and makes check payment conditional. Source
- Oracle Fusion Payables applies supplier tolerance templates; a zero percentage tolerance allows no variance and an active tolerance with no value allows infinite variance. Source
- LedgerSMB's schema keeps discount percentage and days on the counterparty credit account, not on payables or receivables records (commit 0cebbd9). Source
- LedgerSMB's payment functions test discount eligibility with comparisons that differ on the last day of the window (commit 0cebbd9). Source
Tell us what data you need
Share scope, volume, format, timing and licensing needs. Datasets are sourced on request.