[FromForm] isn't available in .NET 6 for minimal API.

Is there any way to make a MapPost() receive parameters from encoded form ?
7 Replies
Pobiega
Pobiega3y ago
Stack Overflow
.NET 6 Minimal API and multipart/form-data
Using the .NET 6 Minimal API, I'm trying to handle multipart/form-data in the POST method. However, with the following code: app.MapPost("/tickets", async (IFreshdeskApiService s, [FromFo...
Patrick
Patrick3y ago
Isn’t supported until .NET 7
Pobiega
Pobiega3y ago
Pobiega
Pobiega3y ago
There are workarounds listed in that SO post
nael4slayer
nael4slayerOP3y ago
Should I use the preview .NET 7 ?
Patrick
Patrick3y ago
If you’re not doing anything serious you can Changes might still happen until November since it’s not RC 🙂
nael4slayer
nael4slayerOP3y ago
Nothing serious at all 🙂
Want results from more Discord servers?
Add your server