Resources · Checks
Every check Temlavo runs on an invoice.
Each result lists its checks in validation.checks. These 15 checks cover arithmetic, currency and dates, duplicates, document type, extraction issues, required data, and line-item coverage. Each one is marked with whether your review policy can change it.
On this page
How checks work
- A check blocks when its severity is
reviewand its status is notpass. Any blocking check makes the resultneeds_review; warnings leave itcompleted. - A finding’s
messageis the sentence in the “What it catches” column, and a finding withinfoseverity has none. A stored result keeps the wording it was created with. - When an arithmetic check’s inputs are missing or unclear, it is
not_evaluablewithinfoseverity. A missing amount is never calculated and added to the result, except a total that the invoice’s charges and its payable plus deductions both give exactly. - Money math uses exact decimals, never floating point. Evaluated arithmetic checks return the equation, the calculated value and the difference.
review_requiredboolean
true when at least one check blocks, which makes the status needs_review.
checksarray of objects
Every check that ran, with its outcome. See checks.
Fields of each item
codestring
The check that ran, such as total_consistency. New codes may be added; see every check.
statusstring
The outcome.
pass- The check passed.
fail- The check found a problem.
not_evaluable- The inputs were missing or unclear, so the check could not decide.
severitystring
How much a failed check matters. A check blocks when its severity is review and its status is not pass.
info- Informational only.
warning- Worth a look; the result can still be completed.
review- Needs a person when the check fails or can't decide.
messagestring · nullable
An explanation for people, or null. Never branch on it.
pathsarray of JSON Pointers
The invoice fields the finding is about, such as /data/totals/total, so you can highlight them in your own review screen.
detailsJSON value · nullableOptional
Check-specific data, such as the equation, calculated value and difference of an arithmetic check.
{
"code": "total_consistency",
"status": "fail",
"severity": "review",
"message": "The invoice total does not equal the subtotal less discount, plus shipping, other charges and any tax the subtotal does not already include.",
"paths": [
"/data/totals/total"
],
"details": {
"equation": "subtotal - discount + shipping + other_charges + tax = total",
"reason": "evaluated",
"actual_total": {
"amount": "1006.80",
"currency": "USD"
},
"calculated_total": {
"amount": "1036.8",
"currency": "USD"
},
"difference": {
"amount": "-30",
"currency": "USD"
}
}
}Branch on status, severity and validation.review_required, not on message text. New check codes may be added over time.
Arithmetic
Recalculates invoice, tax and row equations from the extracted amounts with exact decimal math.
| Check | What it catches | Result |
|---|---|---|
line_item_arithmeticSeverity set by line-item policy | A row’s quantity × unit price does not equal its line total. | Warning under |
tax_arithmeticAlways on | A tax line’s taxable amount × rate does not equal its tax amount. | Needs review. When it is unclear whether the taxable amount already includes the tax, either reading may match. Exact results and the result rounded to the currency’s minor unit in any direction (nearest, down or up) are accepted, as is tax taken out of the taxable amount plus the tax as a tax-inclusive price. Tax rounded line by line rarely shows on the page, so with a complete item list a difference within half a minor unit per line item and per invoice-level discount or charge is left undecided, and a larger one fails. With an incomplete list any difference is left undecided, because the lines that would bound it are missing. |
total_consistencyAlways on | The invoice total does not equal the subtotal less discount, plus shipping, other charges and any tax the subtotal does not already include. | Needs review. Additions are exact, with no rounding tolerance. A discount reduces the size of the subtotal, so on a credit note it reduces the credit. See the Total mismatch sample |
line_items_sum_consistencySeverity set by line-item policy | The row amounts add up to neither the subtotal nor the total. | Warning under |
amount_due_consistencyAlways on | The amount due does not equal the invoice total less payments, credits and amounts withheld, plus any earlier balance carried forward and payable rounding. | Needs review. Runs when the amount due is printed. Additions are exact. When nothing is printed between the total and the amount due, the two must be equal, except that a balance of zero, which no printed payment explains, means the invoice was paid and is left undecided. Undecided when an item between them is unclear or of another kind, such as a commission deducted at payment, and when the amount due is only part of the total, such as an instalment or a requested deposit. |
tax_sum_consistencyAlways on | The tax lines do not add up to the printed total tax. | Needs review. Runs when the extraction marks the tax lines as the complete breakdown of the printed total tax. Allows half a minor unit per tax line, because a total tax rounded once can differ from the sum of separately rounded lines; a larger difference fails. |
Currency and dates
Catches mixed currencies and dates that cannot both be right.
| Check | What it catches | Result |
|---|---|---|
currency_consistencyAlways on | Amounts, or the invoice currency and its amounts, use different currencies. | Needs review. Amounts are never relabeled or converted. |
date_consistencyAlways on | The due date is earlier than the issue date. | Needs review. Runs when both dates are present. |
Duplicates
Compares each submission with earlier completed or needs-review submissions that had duplicate detection on, in the same account and accounting entity.
| Check | What it catches | Result |
|---|---|---|
exact_document_duplicateOn by default · can be turned off | The same source file was submitted before. | Needs review. Returns the earlier document ID. |
possible_invoice_duplicateOn by default · can be turned off | An earlier invoice has the same supplier name and invoice number. | Needs review. Matches even when the earlier invoice arrived as a different file. Returns the earlier document ID. Matching is not fuzzy and does not use dates or amounts. See the Possible duplicate sample |
Document type
Checks that the upload is one invoice before its data is trusted.
| Check | What it catches | Result |
|---|---|---|
document_classificationAlways on | The upload may not be a single invoice. | Needs review. A clear non-invoice, such as a receipt, or an upload with several invoices fails instead and is not billed. |
Extraction issues
Surfaces values the model found conflicting, ambiguous or unreadable instead of silently picking one.
| Check | What it catches | Result |
|---|---|---|
semantic_issueSeverity depends on policy | Conflicts and unclear values in required fields require review; other unclear values are warnings. Under |
Required data
Requires the fields every invoice needs, plus any fields your workflow depends on.
| Check | What it catches | Result |
|---|---|---|
critical_field_unresolvedAlways on | One or more fields every invoice needs could not be resolved. | Needs review. The fields every invoice needs are |
required_field_unresolvedAdded by your policy | One or more fields you required could not be resolved. | Needs review. Choose from 17 supported fields in |
Line-item coverage
Requires usable item rows when your workflow cannot accept a header-only result.
| Check | What it catches | Result |
|---|---|---|
line_items_requirementAdded by your policy | Line items are missing or incomplete, and the line-item policy requires them. | Needs review. Flags no rows, an item list marked partial or unavailable, and rows missing a line total or with neither a description nor a product code. Runs only when |
What checks do not do
- Checks compare the extracted values with each other. They do not re-read or independently verify the source document, so
completedis not a guarantee of accuracy or approval to pay. - Tax arithmetic checks the math on the invoice, not tax compliance.
- Amount due is reconciled with the total through the payments, credits and earlier balances printed between them; an amount due that is only part of the total, such as an instalment, is left undecided. Row amounts are added up only when the item list is marked complete, and a match does not prove that every printed row was captured.
- Review policy changes how some checks affect the outcome; it is not a custom rules engine. Configure review policy.