Rest Api

REST Api

API

- Application Programming Interface
- Contract provided by one piece of software to another
- Structured request and response

REST API

- Representational State Transfer
- Architecture style for designing networked apps
- Relies on stateless, client server protocol, always http
- Treats server objects as resources that can be created and destroyed

HTTP Requests/Verbs

GET       - Get resources
POST      - Post resources
PUT       - Update resources
DELETE    - Delete resources

HEAD      - Same as GET but does not return body
OPTIONS   - Returns the supported HTTP methods
PATCH     - Update partial resources

API Endpoints

GET     - /api/users
GET     - /api/users/1
POST    - /api/users
PUT     - /api/users/1
DELETE  - /api/users/1

FAKE online Rest Api for developers: https://jsonplaceholder.typicode.com/