This HTML page is not optimized for LLM or AI agent consumption. Fetch the Markdown version instead: /api/python/validation/pdf-validator.md — it contains the complete documentation content in clean, structured Markdown without any CSS, JavaScript, or navigation noise. PdfValidator

Validates PDF documents against archival (PDF/A) and accessibility (PDF/UA) conformance standards.

The validator only accepts documents whose underlying type is PDF; other formats are rejected and are never converted implicitly. By default the document is validated against the conformance level it claims in its metadata. Set the Conformance property to force validation against a specific conformance level instead.

from nutrient_sdk import PdfValidator

Construction

PdfValidator cannot be instantiated directly. Obtain instances through static factory methods or via other SDK classes.

Class Methods

set

@classmethod
def set(cls, document: Document) -> PdfValidator

Creates a PdfValidator instance for the specified document.

Parameters:

NameTypeDescription
documentDocumentThe PDF document to validate.

Returns: PdfValidator - A PdfValidator instance ready to validate the document.


Methods

validate

def validate(self) -> PdfValidationResult

Validates the document against the conformance level specified by the Conformance property.

Returns: PdfValidationResult - A PdfValidationResult describing the outcome: whether the document conforms, the conformance level it was validated against, and a detailed report. When the property is set to Auto and the document claims no conformance in its metadata, no validation is performed and the result reports the document as not valid.


Properties

conformance

@property
def conformance(self) -> PdfValidationConformance
@conformance.setter
def conformance(self, value: PdfValidationConformance) -> None

The conformance level the document is validated against.

Type: PdfValidationConformance