ebook_check
Validates one EPUB (a directly hosted public URL or a file attached in chat) against the EPUB 2/3 specification using a pinned local EPUBCheck 5.3.0 engine run in a no-network sandbox. Each call takes exactly one source: the url parameter or the file attachment, never both. Returns the automated verdict: pass boolean, EPUB version, message counts by severity (fatal/error/warning/usage), findings grouped most-severe-first with EPUBCheck rule id (RSC-005, OPF-014, …), file path and line/column, plus a structural inventory (spine items, media types, remote-resource state), SHA-256 of the exact bytes, and truncation metadata. Use for one-file readiness and diagnosis: 'is this ebook valid', 'does this EPUB have specification problems before upload', 'what is wrong with it'. A pass means only that the bytes satisfied the automated profile; it never renders the book, judges accessibility, or guarantees any store will accept it, and human review of how the book reads and looks is always required. Downloads and validates a live EPUB under a 110-second call deadline; tell the user before the call.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | Direct public HTTP(S) URL to the EPUB file bytes, including the protocol, not a ChatGPT file id, local path, cloud-drive share, archive/viewer page, or authenticated URL needing a login. Each call takes either URL sources or attached-file sources, never both STRICT RULE: Ebook check failed: provide either an EPUB URL or an attached EPUB file, not both STRICT RULE: Ebook check failed: provide a public EPUB URL or attach the EPUB file | |
| file | No | An EPUB file attached in chat, up to 25 MB, validated from its exact bytes. Provide either this attachment or url, never both. | |
| maxMessages | No | Maximum spec findings to return, most severe first (default 200); raise it to see more of a very noisy book, lower it to keep the answer short |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| pass | Yes | True when the EPUB has no fatal or error messages against the automated profile | |
| bytes | Yes | Downloaded EPUB size in bytes | |
| counts | Yes | Counts of EPUBCheck findings grouped by severity | |
| sha256 | Yes | SHA-256 hash of the exact validated bytes | |
| finalUrl | Yes | URL after redirects, with query string and fragment stripped | |
| findings | Yes | Bounded spec findings, most severe first, capped by maxMessages | |
| fetchedAt | Yes | ISO timestamp the EPUB was fetched and validated | |
| inventory | Yes | Structural inventory reported for the EPUB container | |
| nonclaims | Yes | What this automated result does not establish | |
| redirects | Yes | Redirect hops followed | |
| truncation | Yes | Finding totals and the applied limit on returned findings | |
| contentType | No | Content-Type the server returned | |
| epubVersion | No | Detected EPUB version, e.g. 2.0.1 or 3.0; omitted when the engine could not detect it | |
| processingMs | Yes | Total processing time in milliseconds | |
| requestedUrl | Yes | The checked EPUB source: the submitted URL with query and fragment stripped, or the attached file's name | |
| engineVersion | Yes | EPUBCheck engine version that produced the verdict | |
| ruleProfileDate | Yes | Release date of the pinned EPUBCheck rule profile | |
| humanReviewItems | Yes | Checks only a qualified human can perform | |
| epubVersionDetected | Yes | Distinguished state: false means the version could not be detected, distinct from a detected-but-invalid version | |
| humanReviewRequired | Yes | Always true: automated conformance never covers how the book reads or renders |