Home > Common Problem > what is rest api

what is rest api

藏色散人
Release: 2020-02-12 11:29:43
Original
6380 people have browsed it

what is rest api

What is rest api?

A software architecture style, design style, not a standard, just providing A set of design principles and constraints. It is mainly used for client and server interaction software. Software designed based on this style can be simpler, more hierarchical, and easier to implement mechanisms such as caching.

Extended content:

Principle conditions:

REST refers to a set of architectural constraints and principles. An application or design that satisfies these constraints and principles is RESTful.

The most important REST principle for web applications is that the interaction between client and server is stateless between requests. Every request from the client to the server must contain the information necessary to understand the request. If the server restarts at any point between requests, the client is not notified. Additionally, stateless requests can be answered by any available server, which is ideal for environments like cloud computing. Clients can cache data to improve performance.

Definition rules:

The resources in REST do not refer to data, but the combination of data and representation, such as "the 10 most recently visited members" and "the 10 most active members" "Members" may have overlapping or identical data, but because of their different representations, they are classified as different resources. This is why the full name of REST is Representational State Transfer.

The resource identifier is URI (Uniform Resource Identifier), whether it is a picture, Word or video file, or even just a virtual service, or XML (a subset of the Standard Universal Markup Language) format, txt file format or other file formats, all uniquely identify resources through URI.

The above is the detailed content of what is rest api. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template