ardalis / ardalis/ApiEndpoints

Consider FromMultiSourceAttribute Necessity and Document It If It Helps

Open
#174 2 comments 3 reactions 0 assignees View on GitHub
Dominant language
C#
Stars
3.2k
Forks
232
PR merge metrics
No merged PRs in 30d

Description

Version 3.1 sometimes had issues with request types being pulled from multiple locations (route, query, body).

[Nick Chapsas shows a solution to this problem here](https://youtu.be/SDu0MA6TmuM?t=647). The MultiSourceAttribute.

I'm not sure if the problem still exists in v4, but if it does we should show how to use this attribute to address it.

References:

- https://stackoverflow.com/questions/45495432/asp-net-core-mvc-mixed-route-frombody-model-binding-validation
- https://www.seeleycoder.com/blog/mixed-model-binding-aspnetcore/

Contributor guide

Open the contributing guide

Research direction

Start by checking whether v4 still reproduces the mixed route, query, and body binding problem described in the issue and linked references. Review the MultiSourceAttribute entry point; done means either documenting its usage for the current behavior or recording that it is no longer needed.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
api, documentation
Issue type
Documentation
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.