MVC & Web Api projects within same Solution

后端 未结 3 604
余生分开走
余生分开走 2021-02-02 11:28

I have an MVC 4 project sitting atop an N-tier application. I now have a requirement to to be able to consume the application programmatically. I have created a new Web API proj

3条回答
  •  谎友^
    谎友^ (楼主)
    2021-02-02 11:56

    You just need to add the routing and API controllers to your existing MVC site where they will all be available under site/api/

提交回复
热议问题