DEV Community

ilija
ilija

Posted on

API and REST in simple terms explained

I see online a lot of confusion about some basic terminology as API and REST. Here I will try to give very simple explanation for anybody new to the field who is perplexed by this very common terms.

API (Application Programing Interface) simply means:

Interface exposed by lets say our backend to be Programmatically (via code) used by some Application (let say our React front-end)

If you want some resource programmatically to integrate in your application you can do that over APIs. Or if you want your resource to be programmatically available and integrated in other people applications you can make some public APIs.

Here Resource can be understood as data in your database. And Interface is simply some endpoint to which application can send request according to rules defined by that API. That's all.

And now what does it mean REST (Representational State Transfer)?

In simply terms it means Transferring State of resource (entry from your database) in some representational format (let's say JSON). And that's it => Representation State Transfer aka REST.

Top comments (0)