Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

100
Visualizações
Receiving HTML File Object in C# API via Post

im trying to Send a File[] to a C# API.

In the same POST request i have other value which get received normaly. Whats the best way to Cast/ Receive an File Object? i could retrieve the .stream() or .arrayBuffer() property, but its a promise and is not fullfilled till im sending the Files.

Is there a C# class / Api i could cast the Files[] in?

This is my API

[Route("CreateJobWithFile")]
[HttpPost]
public Task<ApiResultModel<bool>> CreateJobWithFile(testClass test)
{
    ApiResultModel<bool> result = new ApiResultModel<bool>()
    {
        Data = true
    };
    return Task.FromResult(result);
}

working model

public class testClass
{
    public string Verfahren { get; set; }
    public string Anwendung { get; set; }
    public string Shape{ get; set; }

    public string test4 { get; set; }

    public List<byte[]> Files { get; set; }

    public testClass()
    {
        Files = new List<byte[]>();
    }
}

I tried array of Stream and Byte[] but bot had the Problem that the Promise is not fullfilled

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda