REST API meaning, in plain words

A REST API is a kind of window through which systems exchange data over HTTP. What OWASP says about resources, HTTPS, access control and API keys.

Written by: Mio Kanzaki(Security Analyst (AI))Reviewed by: 千葉圭介Updated

A REST API is a kind of window through which systems exchange data. It is an API (a window through which pieces of software use each other's functions and data) that follows the design idea called REST, and it commonly uses the same HTTP as the web. The OWASP REST Security Cheat Sheet describes REST as a design style that originates in Roy Fielding's doctoral dissertation. The basic unit of information is a "resource".

How does a REST API work?

Picture a restaurant with ordering windows lined up. Each item (resource) has its own window, and you pass requests such as "show me", "add this" and "remove this" in a fixed form. Each window needs to confirm who the customer is.

In a REST API, resources such as members, orders and products are each represented by an address. HTTP methods are used to act on them, for example GET to read and POST to add. The OWASP document says REST APIs are stateless, and that state lives with the resource and not with the user's connection.

For protection, the same document lists serving only over HTTPS, applying access control to each non-public window, and validating input without trusting it. It also says to list the methods you allow and refuse the rest.

How to think about authentication for your own API is covered in the page on API authentication. For an outside look at your pages, the free URL check is open to use.

Why do REST APIs matter?

REST APIs are used in booking systems, member apps and links to outside payment services. The window is called directly, without a screen in between. Hiding a function on the screen gives no protection if the window itself performs no check.

OWASP says an API key helps limit abuse of a public API and track usage. At the same time it cautions against protecting important resources with API keys alone. The operating side should also know the list of windows you expose and who may call each one.

Related terms

  • API: a defined window through which software exchanges data
  • JWT flaws: weaknesses in how a login credential token is handled
  • Rate limiting: a mechanism that refuses a flood of requests in a short time
  • IDOR: a flaw where changing a number shows another person's information

Frequently asked questions

How is a REST API different from an ordinary API?

REST is one design approach for APIs. The OWASP document describes the basic unit of information as the resource, and a stateless design in which each call is complete in itself. APIs with other designs exist too.

If an API key is attached, can I call it safe?

No. OWASP advises not relying on API keys alone to protect important resources. Access control is also needed, so that each window checks whether the user is within the permitted range.

Next step

To check authentication and permission window by window, read API authentication. If you would like us to go over your own API, contact us.

Frequently asked questions

How is a REST API different from an ordinary API?

REST is one design approach for APIs. The OWASP document describes the basic unit of information as the resource, and a stateless design in which each call is complete in itself. APIs with other designs exist too.

If an API key is attached, can I call it safe?

No. OWASP advises not relying on API keys alone to protect important resources. Access control is also needed, so that each window checks whether the user is within the permitted range.

See what an attacker can see, today

The free URL check returns a grade in under a minute. For costs and next steps, book a free consultation.