background preloader

API

Facebook Twitter

REST vs. GraphQL - CodingTheSmartWay.com. REST and GraphQL are two ways to send data over HTTP.

REST vs. GraphQL - CodingTheSmartWay.com

The REST-based approach is the traditional way of doing so and has gained a very high adoption rate in many application stacks in the last years. GraphQL is often presented as a revolutionary new way to think about APIs. Indeed GraphQL is able to overcome major shortcomings of REST. In this tutorial you’ll learn the differences between both technologies and by using many practical examples you’ll be able to understand how GraphQL can help you to build highly flexible APIs for you applications.

Let’s get started … REST And It’s Limitation REST (Representational State Transfer) is an API design architecture used to implement web services. The core concept of REST is that everything is a resource. Multiple Round Trips To Fetch Related Resources Today’s web and mobile applications are often data-driven and require large sets of data combining related resources. Endpoints for posts and suers: mydomain.com/posts/:id.

A bird's eye view on API development - madewithlove. So an API, that’s just output of some JSON code right?

A bird's eye view on API development - madewithlove

No problem, my framework does that automatically. Or if you just want an overview on some best practices, conventions and nifty ways people have done stuff before, this post has you covered. We won’t go in much detail about source code here. This article is language agnostic, whether you use PHP, Ruby, Velato or some obscure Javascript framework you can happily follow along. Please note that not everything here is law, some parts (maybe everything) are open for discussion.

So what are web APIs all about Application Programming Interface, or as the cool kids call it: API, is a collection of endpoints to interact with an application. APIs can be widely different in architecture (XML-RPC, REST, SOAP, …) and data structure (XML, JSON), but it’s very important that they stay as consistent as possible. The basics of REST aren’t that hard to grasp, although there is a lot of misunderstanding on the internet about it.

Frequently Asked Questions About Laravel based APIs - Pine. Developing APIs are getting more and more popular, but still, it’s a bit blurry field for many developers.

Frequently Asked Questions About Laravel based APIs - Pine

We collected some common questions and tried to answer them in one place. 01. What are APIs in general? Wikipedia provides a helpful and understandable description of APIs in general. But let’s summarize the fancy words. Of course, some APIs are more complicated, and some just share data and don’t offer any editing action. 02. Again if you have interested the whole architecture, you should dig a bit deeper. Building RESTful APIs in Laravel. Laravel API Authentication with Tokens - Pine Code - Web Development Writings. Web APIs are interfaces for various software and components.

Laravel API Authentication with Tokens - Pine Code - Web Development Writings

It makes possible to generate the same result by handling requests sent via different technologies. Luckily Laravel and Vue provides a nice and fluent way to work with APIs. APIs in general Web APIs are spots for different technologies to making the same results by handling requests on a standard interface. Because various software and technologies can use the same API, the authentication works differently than a typical web app. Most of the cases, our web app interacts with APIs with the help of a JavaScript framework., like Vue or Angular. Laravel & APIs By default, Laravel provides a nice way to work with APIs. The way it works, Laravel parses the request and searches for appropriate key-value pairs.

Put the pieces together Our first job to configure the axios library, which is a replacement for the Vue resource. Defining Stateful vs Stateless Web Services. Like many industries, the API space has its own jargon.

Defining Stateful vs Stateless Web Services

Many terms are used so often that it’s a common assumption that the related party understands what is being talked about. But for for newcomers, these subtle definitions may not be as apparent. Take the difference between stateless and stateful; an invaluable distinction within the development of APIs and the services that use those systems. Accordingly, in this piece, we’re going to briefly discuss what these terms actually mean. We’ll take a look at what makes statefulness and statelessness so different from one another, and what this actually means in terms of the API.

Stateful To understand statelessness, one must understand statefulness. Frequently Asked Questions About Laravel based APIs - Pine.