public interface IDocumentStorageService { Task<(string objectKey, string sha256, long fileSize)> UploadAsync( Stream fileStream, string contentType, Guid batchId, CancellationToken ct = default); Task GetPresignedUrlAsync(string objectKey, CancellationToken ct = default); Task DownloadAsync(string objectKey, CancellationToken ct = default); /// Returns false when the object is missing from the bucket. Task ObjectExistsAsync(string objectKey, CancellationToken ct = default); /// Uploads bytes only when the object key is not already present. Task EnsureObjectAsync(string objectKey, byte[] content, string contentType, CancellationToken ct = default); /// Ensures the configured bucket exists. Safe to call repeatedly; caches success in-process. Task EnsureBucketAsync(CancellationToken ct = default); }