Skip to main content

Questions tagged [web-api]

Specific APIs that communicate over web protocols, such as ASP.net Web API, as well as APIs that are exposed to web pages for network communication or apps for device communication

96 votes
15 answers
19k views

There's a debate going on in our team at the moment as to whether modifying code design to allow unit testing is a code smell, or to what extent it can be done without being a code smell. This has ...
Lee's user avatar
  • 1,131
75 votes
4 answers
31k views

I was wondering about this. Suppose I have a user resource with id and name fields. If I want to update a field I could just do a PATCH request to the resource like this PATCH /users/42 {"name&...
mattecapu's user avatar
  • 1,012
60 votes
3 answers
52k views

I have used SignalR to achieve real-time messaging functionality in several of my projects. It seems to work reliably and is very easy to learn to use. The temptation, at least for me, is to abandon ...
tacos_tacos_tacos's user avatar
49 votes
12 answers
25k views

I'm managing a team of like 15 developers now, and we are stuck at a point on choosing the technology, where the team is broken into two completely opposite teams, debating over usage of WCF vs. Web ...
Saeed Neamati's user avatar
47 votes
7 answers
46k views

At the past two companies, I've been at, REST API's exist for querying data via webapp - i.e. instead of having the webapp do SQL directly it calls a REST API and that does the SQL and returns the ...
neubert's user avatar
  • 608
43 votes
8 answers
173k views

When transferring object through an API, as in schemaless JSON format, what is the ideal way to return non-existent string property? I know that there are different ways of doing this as in examples ...
imel96's user avatar
  • 3,608
42 votes
1 answer
8k views

Say you were to develop a REST API that provides access to a set of complex, long-running, operations. The typical paradigm for an API like this (as I understand it) usually involves (the client) ...
meci's user avatar
  • 531
41 votes
3 answers
45k views

I am working on a project in MVC that has mobile application so one thing is clear that we have to use Web API so it can used in mobile application. After creating API when we started to develop Web ...
Ruchir Shah's user avatar
35 votes
5 answers
35k views

Having two classes: public class Parent { public int Id { get; set; } public int ChildId { get; set; } } public class Child { ... } When assigning ChildId to Parent should I check first if ...
Konrad's user avatar
  • 1,569
32 votes
4 answers
37k views

So I am just getting started with .Net WebApi and one thing that I am noticing straight away is that there is no Contract defining how the API looks and should be consumed (Request/Responses from each ...
shenku's user avatar
  • 476
31 votes
2 answers
20k views

I'm building a REST API for which several users with different roles will have access to the resources it contains. To keep the scope simple let's take the "student/teacher/class" domain: GET /...
Casper Jensen's user avatar
29 votes
3 answers
93k views

I have a REST API with GETs operations which receive a (long) list of parameters (8 parameters, for example). The aim of this operation is to search and filter elements. Which is the best practice to ...
Jose Alonso Monge's user avatar
27 votes
6 answers
8k views

I am creating an API strcutured web application and in this application we have different layers which are doing their own job. First layer is Validation layer which validate user input and if it ...
Muhammad's user avatar
  • 399
26 votes
3 answers
10k views

While creating a RESTful API, should I use HTTP Verbs on the same URL (when it's possible) or should I create an specific URL per action? For example: GET /items # Read all items GET /...
53777A's user avatar
  • 1,728
23 votes
4 answers
9k views

I don't understand why I keep seeing async/await recommended (or sometimes, even enforced) for ASP.NET Core web applications and APIs. As far as I can tell, every request is already being run on a ...
Medinoc's user avatar
  • 385

15 30 50 per page
1
2 3 4 5
27