namespace AzureAi.Transcriber.Services;

public interface IFileService
{
    Task<List<string>> GetFiles();
}

public class FileService(ILogger<FileService> logger): IFileService
{
    private const string DataFolder = "Data";
    private const string Extension = "wav";
    
    public Task<List<string>> GetFiles()
    {
        logger.LogInformation("Getting files...");
        var files = Directory.GetFiles(DataFolder, $"*.{Extension}", SearchOption.AllDirectories).ToList();
        logger.LogInformation("{count} Files found", files.Count);
        
        return Task.FromResult(files);
    }
}