All Questions
Tagged with asp.net-mvc-web-api .net
10 questions
2
votes
4
answers
7k
views
Web API - How to prevent the POST-ing of entities with custom Id values
Let's say I have the following model:
public class Product
{
public string Id { get; set; }
public string Name { get; set; }
public string Category { get; set; }
public ...
1
vote
1
answer
1k
views
Dotnet (.NET) core MVC WEB API SPA Project and Solution Structure
I am building a new simple web application using dotnet core (.NET Core) and Angular SPA.
Does it make sense to split API and Web App into different projects?
This would complicate things (...
22
votes
2
answers
12k
views
Isn't CQRS overengineering?
I still remember good old days of repositories. But repositories used to grow ugly with time. Then CQRS got mainstream. They were nice, they were a breath of fresh air. But recently I've been asking ...
0
votes
1
answer
713
views
What's the most straightforward way to integrate my company's custom authentication with ASP.NET SSO?
My company has a series of WinForms applications that pretty crudely provides authentication by checking usernames and passwords directly against the database (with a little hashing).
I have a fair ...
0
votes
1
answer
202
views
What's the point/Use of writing out just the method signatures for an API in .Net Web Api
I have been asked to write the signatures for and API end points GET/POST/PUT methods. I'm having a hard time wrapping my head around what the point of this is. My co-worker asked if I could do this ...
5
votes
1
answer
8k
views
why Web API 2 has RouteConfig.cs file?
I m working on Web API project, and it is using WebApiConfig.cs file to defined routs for Web API.
Web API fold RouteConfig.cs file. I have googled and they say RouteConfig.cs is for MVC routing. It ...
5
votes
1
answer
3k
views
What is the clean way to pass my LoginContext down through the layers to the data access layer?
I have inherited an API implemented using ASP.NET WebApi 2. The actions on the controllers are all like this:
public object Get(long id) {
LoginContext loginDetails = GetLoginDetails();
if (...
1
vote
1
answer
2k
views
Invoking a web service in a Web API Project…in which layer to invoke?
I am using Microsoft ASP.NET Web API 2 and one of my end points has to internally invoke a legacy non-Microsoft web service (not asmx or svc) .
Which layer should I invoke this in?
I currently have :...
8
votes
1
answer
3k
views
Is there an advantage to using WCF or WebAPI for mobile?
I'm looking at doing my first mobile development using Mono Touch and Mono for Android. I'd like them to communicate with an ASP.NET MVC 4 site I'm designing. I've worked with WCF and WebAPI in the ...
1
vote
1
answer
3k
views
project layout using webapi
I have the following project structure I would like to implement. I would like to know if there are any pitfalls to structuring my code this way. It is going to be using Microsoft's WebAPI, an MVC 4 ...