API Anti-Patterns

API Anti-Patterns

Author: BJ Burns and Will Gant May 25, 2023 Duration: 50:58

APIs are a huge part of development today and one of the most common types of API out there is a RESTful API. REST stands for representational state transfer, which is a software architecture that imposes conditions on how an API should work. Essentially, it was created as a set of guidelines for how communications should work between disparate systems on a complex communication network (like the internet). REST is implemented atop HTTP and uses the standards in the underlying protocol as part of the standards for communication. In a RESTful API, client and server applications are considered to be independent, that is, details from one should not leak into the other, to the extent possible. This also implies that API calls for the same resource should look the same regardless of where they come from – indeed this is required to decouple the client and the server.

RESTFul APIs are built around the inherent statelessness of HTTP. That is, a persistent connection between the client and server is not assumed. This has profound architectural implications in regards to how resources are accessed and mutated. In order to make this disconnected architecture perform well across the internet, this also means that caching will be used heavily. Caching implies further architectural constraints around resource access, as well as careful coding server side to ensure that items are cached (and removed from cache) appropriately. This helps both client side speed and server side scalability. In addition, the lack of a session makes it far easier to spread a workload across multiple servers, as there is no need to synchronize state between them or keep sessions sticky.

Restful APIs are pretty much bog standard web technology at this point. Not only do complex frontends use them, but clients, QA, and other parts of your own system will often do so as well. While Rest APIs are generally standard at this point, there are a lot of mistakes you can make when designing them that make it harder to use your API, create excess load on the server, or just generally increase the frustration level of all involved parties. Certain antipatterns also look good initially, but end up causing problems later when your system gets more users, or more HTTP savvy integrators working with it. We hope this brief overview is enough to save you some time up front on your next API project.

The post API Anti-Patterns appeared first on Complete Developer Podcast.


Hosted on Acast. See acast.com/privacy for more information.


BJ Burns and Will Gant host the Complete Developer Podcast, a conversation that goes far beyond just writing code. These two seasoned developers built this show from a simple idea: that a career in tech is about more than the latest framework or language syntax. It's about the entire ecosystem you navigate, from the logic on your screen to the dynamics of the business meetings and the long-term path of your career. Each episode feels like pulling up a chair in the break room with colleagues who get it, discussing the real, often unspoken, parts of the job. You'll hear them tackle the intersection of technology, business strategy, and professional growth, making sense of how these pieces fit together in a practical, everyday way. This podcast digs into the questions that don't always have a clear answer in a manual-how to communicate effectively with non-technical teams, ways to approach career advancement, or how to balance deep technical work with the broader goals of a company. It's a resource for anyone who writes code but lives in a much bigger world, offering perspective and discussion that aims to make the whole journey a bit more comprehensible and a lot more manageable. Tune in for thoughtful, grounded talks that treat development as the multifaceted profession it truly is.
Author: Language: English Episodes: 100

Complete Developer Podcast
Podcast Episodes
Managing Large Refactorings [not-audio_url] [/not-audio_url]

Duration: 41:24
As a project becomes more successful, it almost always gets larger. Over time, teams usually get larger as well. Eventually, this means that the previous structure of the application becomes insufficient and needs to be…
Difficult Conversations [not-audio_url] [/not-audio_url]

Duration: 42:19
Difficult conversations are not easy or fun, hence the term difficult. Maintaining interpersonal relationships in the workplace involves problem solving and a fair amount of compromise when dealing with difficult situati…
Database Indexing Mistakes [not-audio_url] [/not-audio_url]

Duration: 40:02
If you aren't constantly dealing with the database, you probably have some misconceptions about how indexes work. These misconceptions not only tend to bite you, but they tend to do so at the worst possible time, when yo…
Basic Psychological Needs of Motivation [not-audio_url] [/not-audio_url]

Duration: 47:41
What motivates you when the rewards seem far off? What drives you to keep pushing when you are tired and worn out? It's not likely the pay or some big reward at the end. It is your own intrinsic motivation.Read more ›The…
Tradeoffs of Single Page Applications [not-audio_url] [/not-audio_url]

Duration: 46:58
In many development shops, Single Page Applications (or SPAs) are the user interface of choice, especially if they are already in use in other systems. While this is often a laudable and reasonable choice, it's a good id…
Success Stabilizers [not-audio_url] [/not-audio_url]

Duration: 44:59
You've made it, you've accomplished your goals. Now what? How do you continue to be successful? Success and failure are intertwined and success if not stable can lead to failure.Read more ›The post Success Stabilizers ap…
Better Dashboards [not-audio_url] [/not-audio_url]

Duration: 42:08
If you are lucky, someone will tell you what they actually want on a dashboard when they tell you to make one. If you're unlucky, you probably are going to have to figure it out as you go. Thankfully, there are some prin…
PCI Compliance [not-audio_url] [/not-audio_url]

Duration: 45:58
Breaches of payment systems are extremely serious. It's a great way not only to have major business problems, but to look like an idiot in front of all your clients, while causing them all kinds of headaches, including p…
OWASP Top Ten 2021 [not-audio_url] [/not-audio_url]

Duration: 37:39
A major security vulnerability will be found in someone's web application this week. The OWASP Top Ten list of web application vulnerabilities has recently been updated. Read more ›The post OWASP Top Ten 2021 appeared fi…
Under Skilled Seniors [not-audio_url] [/not-audio_url]

Duration: 43:00
When you started your career, you might well have been in awe of the senior developers, at least for the first job or two. Later, you might still be impressed with some of them, but others will seem like they were promot…