import type { JobsBase, JobCreateParams, ParsingJob } from "../resources/parsing/jobs.js"; import type { RequestOptions } from "../internal/request-options.js"; import type { Uploadable } from "../core/uploads.js"; import { type MultipartUploadConfig } from "./upload-file.js"; type Constructor = new (...args: any[]) => T; /** * Methods `withParsingJobHelpers` adds to the generated `parsing.jobs` resource. * * The mixin's return type is spelled out so that declaration emit does not have to name the * anonymous class (TS4094: it has the protected `_client` member). */ export interface ParsingJobHelpers { /** * Poll for a job's status until it reaches a terminal state. * * @param jobId - The ID of the job to poll * @param pollIntervalMs - The interval between polls in milliseconds (default: 500) * @param pollTimeoutMs - The maximum time to poll for in milliseconds (default: no timeout) * @param options - Additional request options */ poll(jobId: string, pollIntervalMs?: number, pollTimeoutMs?: number, options?: RequestOptions): Promise; /** * Create a parsing job and wait for it to complete. */ createAndPoll(body: JobCreateParams, pollIntervalMs?: number, pollTimeoutMs?: number, options?: RequestOptions): Promise; /** * Upload a file to the files API and then create a parsing job for it. * Note the job will be asynchronously processed. */ upload(file: Uploadable, body?: Omit, options?: RequestOptions, multipartUpload?: MultipartUploadConfig): Promise; /** * Upload a file and create a parsing job, then poll until processing is complete. */ uploadAndPoll(file: Uploadable, body?: Omit, pollIntervalMs?: number, pollTimeoutMs?: number, options?: RequestOptions, multipartUpload?: MultipartUploadConfig): Promise; } export declare function withParsingJobHelpers>(Base: TBase): (new (...args: any[]) => ParsingJobHelpers) & TBase; export {}; //# sourceMappingURL=parsing-jobs.d.ts.map