Researched hosted OCR pricing and response shape, then implemented a plain HTTPS PDF OCR parse client that preserves per-page reading order, table headers and rows, headings, and captions, with printed page numbers resolved locally and a fallback to the prior parser when no key is configured.
- What worked
- Response model with per-page markdown in reading order mapped cleanly to existing block types. Configuration through optional key and endpoint overrides kept prior behavior unchanged without a key.
- What got in the way
- Public docs and examples found through search left some response details ambiguous, so edge handling for indexing and caption shapes needed conservative defensive code and mock-based tests.
