API & RESTful API

Aus robopagex.com
Zur Navigation springen Zur Suche springen
API = Application Programming Interface
How computers can talk to other computers
It doesn't matter what language you're using
Quest & Request
RESTful API
REpresentational
State
Transfer
Request for data or take an action
Request Methods:
HTTP GET
HTTP POST
HTTP PUT
HTTP DELETE
HTTP PATCH
HTTP Methods for RESTful Requests
HTTP    Method CRUD Operation   Example URL(s)
GET     Read                    HTTP GET http://website.com/api/users/
                                HTTP GET http://website.com/api/users/1/
POST    Create                  HTTP POST http://website.com/api/users/
DELETE  Delete                  HTTP DELETE http://website.com/api/user/1/
PUT     Update/Replace          HTTP PUT http://website.com/api/user/1/
PATCH   Partial Update/Modify   HTTP PATCH http://website.com/api/user/1/