HTTP Request Methods

1. GET

GET Method is used to request information from a website, Server or from API.

Example: GET/api/employee/{employee-id}

2. POST

This Method is used to create a new resource in server. We can send data to the server in the request body.

Example: POST/api/employee/department

3. PUT

PUT Method is used to update an existing record by sending the updated data as the content to request body to the server.

Example: POST/api/employee/55445

4. DELETE

This Method is used to remove resources from the server.

Example: DELETE/api/employee/55445

5. PATCH

PATCH and PUT are similar use to updates a resource, but it will update data partially but not fully.

Example: PATCH/api/employee/55445{"Name: Employee Name"}

6. HEAD

This Method is like the GET but it doesn't have any response body.

Example: HEAD/api/employee

7. OPTIONS

This Methos is used to get the information about the possible communication options from the given URL.

Example: OPTIONS/api/main.html/"Text"

8. TRACE

This Method creates a loop back test with the same request body that the client send to the server before, and the successful response code is 200.

Example: TRACE/api/main.html

9. CONNECT

This Methos is used for making end to end connections between a client and server.

Example: CONNECT www.testwebsite.com:445 HTTP/1.1

HTTP Methods

Thank You..!