/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 * @generated-id: 9f1e92f79055
 */
import * as z from "zod/v4";
import { remap as remap$ } from "../../lib/primitives.js";
import { safeParse } from "../../lib/schemas.js";
import { OCRImageObject$inboundSchema, } from "./ocrimageobject.js";
import { OCRPageConfidenceScores$inboundSchema, } from "./ocrpageconfidencescores.js";
import { OCRPageDimensions$inboundSchema, } from "./ocrpagedimensions.js";
import { OCRTableObject$inboundSchema, } from "./ocrtableobject.js";
/** @internal */
export const OCRPageObject$inboundSchema = z
    .object({
    index: z.int(),
    markdown: z.string(),
    images: z.array(OCRImageObject$inboundSchema),
    tables: z.array(OCRTableObject$inboundSchema).optional(),
    hyperlinks: z.array(z.string()).optional(),
    header: z.nullable(z.string()).optional(),
    footer: z.nullable(z.string()).optional(),
    dimensions: z.nullable(OCRPageDimensions$inboundSchema),
    confidence_scores: z.nullable(OCRPageConfidenceScores$inboundSchema)
        .optional(),
}).transform((v) => {
    return remap$(v, {
        "confidence_scores": "confidenceScores",
    });
});
export function ocrPageObjectFromJSON(jsonString) {
    return safeParse(jsonString, (x) => OCRPageObject$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OCRPageObject' from JSON`);
}
//# sourceMappingURL=ocrpageobject.js.map