diff --git a/FunctionApp/UploadDocumentToLoxo.cs b/FunctionApp/UploadDocumentToLoxo.cs index 1974741..17ef723 100644 --- a/FunctionApp/UploadDocumentToLoxo.cs +++ b/FunctionApp/UploadDocumentToLoxo.cs @@ -66,7 +66,8 @@ public async Task Run( using (var content = new MultipartFormDataContent()) { var fileContent = new ByteArrayContent(fileData); - var fileName = Uri.EscapeDataString($"Form {DateTime.Now}.pdf"); + var fileName = $"Form_{DateTime.Now:yyyy_MM_dd_HH_mm_ss}.pdf"; + fileContent.Headers.ContentType = new MediaTypeHeaderValue("application/octet-stream"); content.Add(fileContent, "document", fileName);