Skip to main content

Questions tagged [api-design]

Application Programming Interface (API) Design discusses best practices for creating interfaces between computer programs, web servers or libraries intended for general purpose or public use. In contrast to a user interface, which connects a computer to a person, an application programming interface connects computers or pieces of software to each other.

10 votes
5 answers
1k views

I am having a hard time to deal with one particular issue in API design that might be very common. Let me give the concrete example I have: I am writing a RESTFul API for a store and have the ...
user1620696's user avatar
  • 5,105
2 votes
5 answers
448 views

I am trying to improve the readability of my code and make things more self documenting (or at the very least learn new things about C++) for example: // OLD Texture LoadTexture(const std::string& ...
steamdog's user avatar
0 votes
1 answer
109 views

I am designing an interface for C code to add functions and modules to my programming language. I am wondering if this is an OK design for a println function. This function would take in a vararg of ...
rufu's user avatar
  • 3
2 votes
3 answers
333 views

Say I have the following header #ifndef WINDOW_HPP #define WINDOW_HPP // includes... namespace window { struct Window { GLFWwindow *handle = nullptr; }; struct ...
user avatar
0 votes
2 answers
240 views

I am doing the frontend for a Java Spring backend. The project uses JavaFX for the front but I a migrating it for web usage (with VueJS). When I make an API call to retrieve an object, I am receiving ...
Bernardo Benini Fantin's user avatar
1 vote
1 answer
248 views

I am currently rethinking my API response schema and caching strategy while implementing ETag-based caching for a paginated REST API (for example, listing places). Each paginated response looks like ...
Meds's user avatar
  • 19
1 vote
3 answers
470 views

I’m building an app that lets users manage data across multiple tables. I also expose an API so they can fetch their data and process it in external services. I’d like to enhance the API to support ...
Axel Chalayer's user avatar
1 vote
2 answers
710 views

I just started learning about the specification, but I still have some doubts about why GraphQL simply hasn't replaced REST since it was created. REST APIs are very inflexible and straightforward. ...
Sami Daniel's user avatar
2 votes
1 answer
256 views

I'm working on a web-based app that uses Django and Angular. This app uses several external APIs to fetch environmental data from different monitoring networks. We then use these data to perform ...
stray_dog's user avatar
0 votes
1 answer
207 views

I want to create one service that reads data from two databases and passes it to the customer devices. Is this an overall bad design decision? I think that since it is only read-only, it should be ...
Travis's user avatar
  • 121
2 votes
8 answers
607 views

Say I have a contract returning a type: type CreditCard = { scheme: "Visa" | "Mastercard" } and later we decided to include Amex as card type, then making this change: type ...
dwjohnston's user avatar
  • 2,799
2 votes
1 answer
223 views

Preface: This will not be available publicly or to third parties, so I am not concerned about users having the background knowledge to properly form GET requests. These are also not only analytical ...
user avatar
2 votes
2 answers
202 views

I'm facing a tricky situation that might result from a not thoroughly thought-out design, and I'm hoping to understand whether a deadlock might be a realistic cause – and if so, how to prevent similar ...
ComfortableOnion's user avatar
2 votes
3 answers
428 views

A typical search query looks something like GET example.com/entity/search?q=John If we want to add some filtering to this endpoint, we could for example add ...&filter= followed by a URL encoding ...
aioobe's user avatar
  • 957
1 vote
3 answers
382 views

I recently read through Hypermedia Systems, and found its arguments incredibly compelling. The book brought a lot of clarity and structure to ideas and frustrations that have been bouncing around in ...
DMJ's user avatar
  • 121

15 30 50 per page
1
2 3 4 5
79