REST verbs specify an action to be performed on a specific resource or a collection of resources. When a request is made by the client, it should send the following information in the HTTP request:
- The REST verb
- Header information
- The body (optional)
As we mentioned previously, REST uses the URI to decode the resource to be handled. There are quite a few REST verbs available, but six of them are used particularly frequently. They are presented, along with their expected actions, in the following table:
REST Verb | Action |
GET | Fetches a record or set of resources from the server |
OPTIONS | Fetches all available REST operations |
POST | Creates a resource or a new set of resources |
PUT | Updates or replaces the given record |
PATCH | Modifies the given record |
DELETE | Deletes the given resource |
The status of these operations can be known from HTTP...