ASP.NET Web API does not allow Lengthy base64 URI

前端 未结 2 1688
野的像风
野的像风 2021-01-22 10:58

I\'m trying to receive a lengthy base64 string from my Android Client and then decode it to a bitmap in my Web API Project to be uploaded as an image to an Azure BLOB Storage. H

2条回答
  •  甜味超标
    2021-01-22 11:49

    (I have deleted the other one, I want to keep this one because the issue was using asp.net 5 beta 8 and is more recent)

    I had this issue recently and the parameter was moved to receive a byte[] (byte array) From Body

    First I tried from body and the string was received but the string was truncated and the file can't be recreated in the server side.

    In my application the base64 came from a conversion of an array buffer created from an input file.

    The base64 is sent in a json from angular.

提交回复
热议问题