import { type docs_v1 } from "@googleapis/docs"; import * as z from "zod"; export declare const GOOGLE_DOCS_READ_REQUIREMENT: import("@automate.ax/catalog").ScopeRequirementGroup; export declare const GOOGLE_DOCS_WRITE_REQUIREMENT: import("@automate.ax/catalog").ScopeRequirementGroup; export declare const GOOGLE_DOCUMENT_TAB_SCHEMA: z.ZodObject<{ childTabs: z.ZodArray; index: z.ZodNumber; tabId: z.ZodString; text: z.ZodString; title: z.ZodString; }, z.core.$strip>; export declare const GOOGLE_DOCUMENT_SCHEMA: z.ZodObject<{ documentId: z.ZodString; revisionId: z.ZodOptional; tabs: z.ZodArray; index: z.ZodNumber; tabId: z.ZodString; text: z.ZodString; title: z.ZodString; }, z.core.$strip>>; title: z.ZodString; url: z.ZodURL; }, z.core.$strip>; export declare const GOOGLE_DOCUMENT_UPDATE_SCHEMA: z.ZodObject<{ documentId: z.ZodString; revisionId: z.ZodOptional; }, z.core.$strip>; /** * Creates the official Docs client from a refreshed Google secret. * * @param secret - Refreshed Google account secret. */ export declare function getGoogleDocsApi(secret: Record): docs_v1.Docs; /** * Accepts a raw document ID or standard Google Docs URL. * * @param document - Raw document ID or URL. * @throws When a URL is not a recognizable Google Docs document URL. */ export declare function normalizeGoogleDocumentId(document: string): string; /** * Converts a provider document into the stable public shape. * * @param document - Provider document response. * @throws When required document metadata is absent. */ export declare function normalizeGoogleDocument(document: docs_v1.Schema$Document): { documentId: string; revisionId: string | undefined; tabs: { childTabs: /*elided*/ any[]; index: number; tabId: string; text: string; title: string; }[]; title: string; url: string; }; /** * Converts a provider update response into the stable public shape. * * @param response - Provider batch-update response. * @throws When the response omits its document ID. */ export declare function normalizeGoogleDocumentUpdate(response: docs_v1.Schema$BatchUpdateDocumentResponse): { documentId: string; revisionId: string | undefined; }; /** * Selects the requested Docs revision guard. * * @param input - Optional required or target revision. * @param input.requiredRevisionId - Revision that must match exactly. * @param input.targetRevisionId - Revision the write should target. */ export declare function googleDocsWriteControl(input: { requiredRevisionId?: string; targetRevisionId?: string; }): { requiredRevisionId: string; targetRevisionId?: undefined; } | { targetRevisionId: string; requiredRevisionId?: undefined; } | undefined; /** * Creates a provider text range. * * @param input - Start, end, and optional tab coordinates. * @param input.endIndex - Exclusive range end. * @param input.startIndex - Inclusive range start. * @param input.tabId - Optional document tab ID. */ export declare function googleDocsRange(input: { endIndex: number; startIndex: number; tabId?: string; }): { endIndex: number; startIndex: number; tabId: string | undefined; }; /** * Converts a validated hex color to the Docs RGB shape. * * @param value - Six-digit hex color. */ export declare function hexToGoogleColor(value: string): { color: { rgbColor: { blue: number; green: number; red: number; }; }; }; //# sourceMappingURL=lib.d.ts.map