UNPKG

svector-sdk

Version:

Official JavaScript and TypeScript SDK for accessing SVECTOR APIs.

19 lines (18 loc) 867 B
export declare function toFile(value: any, filename?: string, options?: { type?: string; }): Promise<File>; export declare function isNodeEnvironment(): boolean; export declare function isBrowserEnvironment(): boolean; export declare function getDefaultFetch(): typeof fetch; export declare function imageToBase64(file: File | Buffer | Uint8Array): Promise<string>; export declare function detectImageMimeType(data: Buffer | Uint8Array): string; export declare function isValidImageUrl(url: string): boolean; export declare function isValidBase64Image(base64: string): boolean; export declare function createImageContent(imageInput: string | File | Buffer | Uint8Array, text?: string, detail?: 'low' | 'high' | 'auto'): Promise<Array<{ type: 'text' | 'image_url'; text?: string; image_url?: { url: string; detail?: string; }; }>>;