I want to route all api calls to one controller. Im using MVC and what i would like to do is have dynamic endpoints so basically whatever url you use it will point to one controller which does logic. The thing that makes it more tricky is that i want to know which controller is being called so for example if there is an Get at: "https://{url}/project/id" i want it to point to my "dynamic" controller and have "project" as an parameter(or something that can tell me what endpoint was used) so i know which controller is called.
I know this is not a nice way of setting up an API but currently this seems to best fit our needs with the requirements we have.
[edit] I see ive messed up my question since i was mixing up the MVC controller and ApiController. I ended up using the answer in this thread: Route all Web API requests to one controller method