UNPKG

@realitydefender/realitydefender

Version:

SDK for the Reality Defender API for deepfake detection

28 lines (27 loc) 985 B
/** * Media upload functionality */ import { HttpClient } from '../client/types'; import { SignedUrlResponse } from '../types/api'; import { UploadOptions, UploadResult } from '../types/sdk'; /** * Get a signed URL for uploading a file * @param client HTTP client * @param fileName Name of the file to upload * @returns Signed URL response */ export declare function getSignedUrl(client: HttpClient, fileName: string): Promise<SignedUrlResponse>; /** * Upload file content to a signed URL * @param client HTTP client * @param signedUrl URL for uploading * @param filePath Path to the file to upload */ export declare function uploadToSignedUrl(client: HttpClient, signedUrl: string, filePath: string): Promise<void>; /** * Upload a file for analysis * @param client HTTP client * @param options Upload options * @returns Upload result with request and media IDs */ export declare function uploadFile(client: HttpClient, options: UploadOptions): Promise<UploadResult>;