UNPKG

portkey-ai

Version:
31 lines (30 loc) 1.19 kB
import { ApiClientInterface } from '../_types/generalTypes'; import { ApiResource } from '../apiResource'; import { RequestOptions } from '../baseClient'; import { Uploadable } from 'openai/uploads'; export interface UploadCompleteParams { part_ids: Array<string>; md5?: string; [key: string]: any; } export declare class Uploads extends ApiResource { parts: Parts; constructor(client: any); create(_body: UploadCreateParams, params?: ApiClientInterface, opts?: RequestOptions): Promise<any>; cancel(uploadId: string, params?: ApiClientInterface, opts?: RequestOptions): Promise<any>; complete(uploadId: string, _body: UploadCompleteParams, params?: ApiClientInterface, opts?: RequestOptions): Promise<any>; } export declare class Parts extends ApiResource { create(uploadId: string, _body: PartCreateParams, params?: ApiClientInterface, opts?: RequestOptions): Promise<any>; } export interface UploadCreateParams { bytes: number; filename: string; mime_type: string; purpose: 'assistants' | 'batch' | 'fine-tune' | 'vision'; [key: string]: any; } export interface PartCreateParams { data: Uploadable; [key: string]: any; }