(in async function) using (Stream fileStream = new FileStream(filePath, FileMode.Create)) { await file.CopyToAsync(fileStream); }