What's the difference between REST & RESTful

后端 未结 15 1276
情深已故
情深已故 2020-12-11 15:13

What\'s the difference between a REST system and a system that is RESTful?

From a few things I\'ve read most so called REST services are actually RESTful services. S

相关标签:
15条回答
  • 2020-12-11 15:53

    Representational state transfer (REST) is a style of software architecture. As described in a dissertation by Roy Fielding, REST is an "architectural style" that basically exploits the existing technology and protocols of the Web.

    RESTful is typically used to refer to web services implementing such an architecture.

    0 讨论(0)
  • 2020-12-11 15:54

    REST(REpresentation State Transfer) is an architecture using which WebServices are created.

    and

    RESTful is way of writing services using the REST architectures. RESTful services exposes the resources to identify the targets to interact with clients.

    0 讨论(0)
  • 2020-12-11 15:55

    There are 4 levels of API defined in the Richardson Maturity Model. These are defined as:

    • level 0: any system that has a single endpoint for all its apis(SOAP or RPC fall in this category). Level 0 apis can also resemble "commands".

    • level 1: a ResourceUri described system. This is a system that defines multiple entity-based URIs (instead of having a single endpoint like a level 0 systems would). These URIs can use different http actions (POST, GET, PUT, etc) to implement different actions against that resource.

    • level 2: aka level 1 w/ a compliant use of Standard HTTP methods/verbs and multi status code responses

    • level 3: aka level 2 plus HATEOAS (hypermedia included in the response which describes additional calls you can make)

    While levels 1, level 2, and level 3 can be considered as REST systems, only the stricter levels (aka level 2 and level 3) are considered to be RESTful.

    So essentially all RESTful apis are REST apis, but not all REST apis are RESTful

    definition of the Richardson Maturity Model

    0 讨论(0)
提交回复
热议问题