TPDFInvoiceValidationRequest

Data types, invoices, compliance

Description

TPDFInvoiceValidationRequest carries the invoice XML and the trusted rule package that ValidateInvoiceBusinessRules and its variants submit to an invoice validation provider.

ValidateInvoiceBusinessRules replaces XMLBytes with the decoded selected attachment, so the caller cannot substitute unrelated XML for the invoice stored in the PDF.

Syntax

Delphi

TPDFInvoiceValidationRequest = record
  XMLBytes: AnsiString;
  Rules: TPDFInvoiceRuleSet;
  RequireSchema, RequireSchematron: Boolean;
  TimeoutMS, MaxOutputBytes: Integer;
end;

Fields

XMLBytesDecoded invoice XML bytes; overwritten with the selected attachment content before validation
RulesVersioned rule package and the schema or Schematron files the provider executes
RequireSchemaWhen True, the XML Schema stage is requested
RequireSchematronWhen True, the Schematron business-rule stage is requested
TimeoutMSWall-clock budget in milliseconds for the validation run
MaxOutputBytesUpper bound in bytes for diagnostics and issue output retained from the provider

Remarks

PLDefaultInvoiceValidationRequest requests both stages, sets TimeoutMS to 30000 and MaxOutputBytes to 8 MiB.

A stage that is not requested remains ivstNotChecked in the report and makes no claim about the rules it covers.

See also

ValidateInvoiceBusinessRules, TPDFInvoiceValidationReport, IPDFInvoiceValidationProvider