RESTful API design
For an API to be considered RESTful, it must adhere to a few principles that stay true to the original concepts behind the Web and are already known to most developers. Such an approach allows us to make sure we aren't building anything strange or unusual into our API while also giving our users a head start toward consuming it, since they are already familiar with its concepts.
Some of the important RESTful design concepts are:
HTTP methods describe the kind of action to take; for example,
GET
methods will only ever read data, whilePOST
requests will create somethingData is expressed as a collection of resources
Actions are expressed as changes to data
URLs are used to refer to specific data
HTTP headers are used to describe the kind of representation coming into and going out of the server
The following table shows the HTTP methods and URLs that represent the actions that we will support in our API, along with a brief description and an example use case of how we intend the...